sambasivarao laghuvarapu

Greenhorn
+ Follow
since Jun 07, 2007
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by sambasivarao laghuvarapu

Hi All,

I want to replace some string iam using the replaceAll method but it's not giving the proper output.can anyone explain what is the exact functionality of the string replaceAll method.

Thanks.
14 years ago
The java.util.prefs.WindowsPreferences is the concrete implementation of AbstractPreferences in the Windows platform. This class provides methods like WindowsRegQueryValueEx, etc. Using Reflection, one can use the methods in this class to query string values under HKEY_LOCAL_MACHINE and HKEY_CURRENT_USER. For some reason, the java wrapper for WindowsRegQueryValueEx only seems to work for string values. I get a null for values of type REG_DWORD, which I guess makes this approach pretty useless except in times of desperation. Please Tell me how I can retrive REG_DWORD values.
14 years ago
Hi All,

How to read the file using BufferedReader in reverse oreder.
please give the example code.

Thanks.
15 years ago
Arraylist l=new Arraylist();
l.add("samba");
l.add("siva");
String[] s=(String[])l.toArray(); //line 1


in line 1 i am getting classCastException.can anyone explain how to convert that objcet Array to string Array
Hi,
class A{
public void finalize(){
int i=8/0;

}
public static void main(String[] args){
A a=new A();
a=null;
System.gc();
}
}
if the garbage collector call the finalize method.what will happen.please explain.
class Test {

public static void main(String[] args) {
m1();
}
static byte m1( ) {
final char c1 ='2';
return c1; //line 1
}
static byte m2(final char c2) {
c2='3';
return c2; //line 2
}
}

while i am compiling this code i am getting compiler error at line 2 only.i am not getting compiler error at line 1 why.please help anybody.
16 years ago
Hi
class Test {

public static void main(String[] args) {
m1();
}
static byte m1( ) {
final char c1 ='2';
return c1; //line 1
}
static byte m2(final char c2) {
c2='3';
return c2; //line 2
}
}

while i am compiling this code i am getting compiler error at line 2.please anybody help me
16 years ago
Sorry it was wrong from my end. My intention was - Why it is returning "false"?

Thnaks
16 years ago


In the above code, why is it returning "true"?.

Thanks
16 years ago