Hi
Can someone explain how the G1 Garbage Collector works please? I haven't been able to find any comprehensive, easy-to-understand descriptions anywhere yet.
Thanks
Hi,
I'm creating a custom WinForms TextBox control, like this:
class MyTest : TextBox
{
protected override void OnEnter(EventArgs e)
{
this.BackColor = Color.Yellow;
}
protected override void OnLeave(EventArgs e)
{
this.BackColor = Color.White;
}
}
When I build the project, I cannot see the control. Can anyone explain why not?
Thanks in advance.
Consider the following code which shows compile time error :
#include <stdio.h>
int main(int argc, char** argv)
{
int x=5,y=0,z=2;
int a=z?x,y?x:(y); // but z?x,y?x:y:z is not showing any error
printf("%d",a);
return 0;
}
Please help me explain the reason why z?x,y?x:y:z is not showing any error?
I have following code snippet:
class ABC{
public:
int a;
void print(){cout<<"hello"<<endl;}
};
int main(){
ABC *ptr = NULL:
ptr->print();
return 0;
}
It runs successfully. Can someone explain it?
I was reading an article on handling Out Of Memory error conditions in Java (and on JBoss platform) and I saw this suggestion to reduce the size of the threadstack. Can anyone explain how "reducing" the size of threadstack will help with a max memory error condition?
http://community.jboss.org/wiki/OutOfMemoryExceptions
I would like for someone to explain this to me:
function myFunction(array){
array = $.grep(array, function(n,i){return n > 1 });
}
var mainArray = [1,2,3];
myFunction(mainArray);
document.write(mainArray) // 1,2,3, but i'm expecting 2,3
but if i do something like
array[3] = 4;
in place of the $.grep line, i get 1,2,3,4. Shouldn't mainArray become the new array created by $.grep?
I'm working on some C code filled with macros like this:
#define SAFE_FREE(x) do { if ((x) != NULL) {free(x); x=NULL;} } while(0)
Can anyone explain what this macro does, and why do {} while(0) is needed? Wouldn't that just execute the code once?
i am doing a project that has some simple values(login,password,name,age). I was searching on the internet how to create an excel file on Visual C++, and i cant undestand it . I just want the simple way, i just want to see on my excel files 2 colums one having some login codes of my program and on the other the passwords. My programing level its not really high and im not an english speaker, so id like you guys to explain a bit or give me something simple.
Thanks for your time
As I know, from the relational database theory, a select statement without an order by clause should be considered has not particular order. But actually in SQL Server and Oracle (I've tested on those 2 platforms), if I query from a table without an order by clause multiple times, I always get the results in the same order. Does this behavior can be relied on? Anyone can help to explain a little?
Thanks!
I have following code snippet:
class ABC{
public:
int a;
void print(){cout<<"hello"<<endl;}
};
int main(){
ABC *ptr = NULL:
ptr->print();
return 0;
}
It runs successfully. Can someone explain it?
Could any1 explain how can i transform ll(1) parsing table to lr(1) parsing table? Or are there any tables already for lr1 mathematical parsing(+,-,/,*,^)?
In MSSQL Management Studio I created a maintenance plan but it won't work
Error is; "Message Executed as user: LITESPELL-19C34\Administrator. Microsoft (R) SQL Server Execute Package Utility Version 10.0.1600.22 for 32-bit Copyright (C) Microsoft Corp 1984-2005. All rights reserved. The SQL Server Execute Package Utility requires Integration Services to be installed by one of these editions of SQL Server 2008: Standard, Enterprise, Developer, or Evaluation. To install Integration Services, run SQL Server Setup and select Integration Services. The package execution failed. The step failed."
But in Microsoft page http://www.microsoft.com/sqlserver/2008/en/us/web.aspx in Automate tasks and policies section it is written that backup can be scheduled in this edition but how?
Can somebody explain me why the following piece of code fails to compile. The error is: "Possible loss of precision." :
byte a = 50;
byte b = 40;
byte sum = (byte)a + b;
System.out.println(sum);
Thank you.
I was asked to provide an image of my Ubuntu Server 9.10 with LAMP made by VMware Player for setting up a VPS. Most of the information on the internet is about Ubuntu Desktop and Windows, so I am a bit confused.
Could you explain me how I can do that?
Possible Duplicates:
Using Inner classes in C#
Inner classes in C#
Class declared inside of another class in C#
Does C# support the concept of inner classes? If so, what are the benefits?
Could someone please explain this to me?
I've noticed that a lot of projects have the following structure:
Project-A
bin
lib
src
main
java
RootLevelPackageClass.java
I currently use the following convention (as my projects are 100% java):
Project-A
bin
lib
src
RootLevelPackageClass.java
I'm not currently using Maven but am wondering if this is a Maven convention or not or if there is another reason. Can someone explain why the first version is so popular these days and if I should adopt this new convention or not?
Chris
As i understoond, if we have local service of some application, as soon as the application goes down, the service goes down as well - is that true?
and if it is, how can we make an application to run all the time without go down? (without using Alarm manager). i though that the purpose of local service is to answer this situation: " to make the application everlasting"
please, if some1 could explain me this better,
thanks,
ray.
Best to explain with an example.
TabControl has Tab1 and Tab2.
I'm trying to make it so when Tab1 is selected, Button1 is visible and stays visible.
When Tab2 is selected, Button1 is invisible and stays invisible. I need it to work when the Tab is clicked, not when the content area of the Tab is clicked.
Thank you.
I have read and read over MSDN, etc. Ok, so it signals the end of a batch.
What defines a batch? I don't see why I need go when I'm pasting in a bunch of scripts to be run all at the same time.
I've never understood GO. Can anyone explain this better and when I need to use it (after how many or what type of transactions)?
I used this tip top hide my menu bar in a bunch of applications, which is a great way to get more free screen space. The one downside is that (for inexplicable reasons) it disables Spotlight when I'm in those applications--e.g. even if I hover over the menu bar to make it appear, clicking on the Spotlight icon does nothing.
I have a plan to work around this: I'd like to launch Spotlight using QuicKeys, which lets you run terminal commands using keyboard shortcuts. But to do that, I need to know how to launch Spotlight with a terminal command. Does anyone know how to do this?
I'm on OS X 10.6.
I want to find out which tables have been modified in the last hour in a MySQL database. How can I do this?
I am new to MySQL so please try to explain it as simply as you can.
thank you!
May i inquire more knowledge on marshaling and unmarshaling of kml codes? Regarding those used in Google earth. I need to do a project on flight airlines, linking them with an arc which is a polygon to connect placemarks with placemarks. I've tried to compile sample codes of HelloKML but still unable to marshal and produce the kml codes itself. Please someone explain marshaling and unmarshaling of codes and producing of kml codes. Thanks in advance.
In his book programming in scala (Chapter 5 Section 5.9 Pg 93)
Odersky mentioned this expression "bills !*&^%~ code!
In the footnote on same page:
"By now you should be able to figure out that given this code,the Scala compiler would
invoke (bills.!*&^%~(code)).!()."
That's a bit to cryptic for me, could someone explain what's going on here?
void display(int a)
{
printf("\n%d",a);
if(--a)
display(a);
printf("\n%d",a);
}
main()
{
display(4);
}
Please explain the above program. i can't understand.what is the output.ya sir i got oupt like this 4 3 2 1 0 1 2 3 how is it sir