antraarora

Ranch Hand
+ Follow
since Jul 27, 2000
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 antraarora

Thanks to all of you!!! With your guidance and blessings, I've made it.
thanks,
Antra
Use socket method. "in" is an InputStream constructed by "InputStream in = new Socket().getInputStream();"
Which constructor is the most adequate for transmition of ASCII data from the socket?
A. BufferedReader(InputStreamReader(in, "8859_1"))
B. BufferedReader(InputStreamReader(in))
C. DataInputStream(in)
D. BufferedInputStream(DataInputStream(in))
E. InputStreamReader(in)
The given answer at the back of book is A. Can someone expalin why? I am clueless.
Can the method SetConstraints() be repeatedly used?
Can somebody help me with this one.
Which variables should you use to declare the class Hexagon. Hexagon is drawable and it has several vertices, Colors that can be stored by a Vector and a flag of boolean type. What can you use to declare the member variables of this class?
A. Object
B. boolean
C. Vertice
D. Vector
E. Hexagon
Since none of the modifiers are given...do we assume that we have to specify the modifier(public) as a part of declaration?
Should it be
public class Hexagon extends drawable(vertice integer, flag boolean, color vector){}
Now, 1. I have used a lot of words not given. Is that right?
2. What is the correct answer?
3. Should {} be used while decalaring a class?
Can a programmer code to run the GC whenever you want to?
Thanks Surya! That was helpful!
Could somebody help me with this? It's from Applied reasoning mock exam?
A panel has grid layout with 2 rows and 2 columns. there is a button in each cell and another button is added to the pnale as follows:-
aPanel.addbutton(new button("Bob")). Where will the new button be placed?
A. row1 col3
B. row1 col1
C. row3 col1
D. row2 col3
E. row2 col2
I marked "A" as the number rows remains the same and columns can be increased. But the correct answer was "E". I am confused???
It sure doesn help!!! thanks!!! But I have another small question. Since equals(0 acts the same way as == in StringBuffer. does that mean that if
String Buffer s1= new String Buffer("10");
String Buffer s2= new String Buffer("10");
then would s1.equals(s2) return false???
Could somebody explain to me what happens when "==" and "equals()" is applied to wrapper classes and also String Buffer) ??
like for eg:
Integer ai= "10";
Integer bi = "10";
what will be the result of :
1. ai==bi
2. ai.equals(bi)
3. What if the word "new" was added in their declaration/initialization?
4. How different is it for String Buffer?
5. How different is it for primitive data types?
Thanks,
Antra

Thanks Vani...that helps!!!
Please help me. I think the right answer is D as it is post-increment. But the right answer is B. Why???
What is the output of the following code:-
int x=4;
int y=7;
while(x++<5 && y++<8){
}
System.out.println("x=" +x +" y=" +y);
A. x=5 y=8
B. x=6 y=8
C. x=6 y=9
D. x=4 y=7
Which of the given options are true about the rectangle drawn by the following code ?
g.drawRect(30,30,200,200);
A. rectangle is a square
B. width=200 pixels
C. width=170 pixels
D. bottom right corner x=200,y=200
E. bottom right corner x=230,y=230
The answer given for this question was A,B,E. I think just A,B. I think the bottom right corner is x=230,y=30. Could somebody explain why E is also right.