| Author |
Message |
Singachea fourth grade
Joined: 19 Nov 2005 Posts: 258
|
Posted: Sun Dec 04, 2005 6:09 pm Post subject: Want to take a quiz? |
|
|
Any one intereted in Java?
Take a quick basic quiz in java right now.
link: http://www.geocities.com/singachea/quizJava.htm
Last edited by Singachea on Wed Dec 14, 2005 3:46 pm; edited 1 time in total |
|
| Back to top |
|
 |
guitarman fourth grade
Joined: 04 Nov 2005 Posts: 728
|
Posted: Sun Dec 04, 2005 6:27 pm Post subject: |
|
|
Hahah, I got 6/10...hoho
|
|
| Back to top |
|
 |
Singachea fourth grade
Joined: 19 Nov 2005 Posts: 258
|
Posted: Sun Dec 04, 2005 6:43 pm Post subject: |
|
|
| guitarman wrote: |
| Hahah, I got 6/10...hoho |
Which question do you think it's the most tricky one? For me, i think the last question is very tricky. It's extracted from NTU exam paper
|
|
| Back to top |
|
 |
guitarman fourth grade
Joined: 04 Nov 2005 Posts: 728
|
Posted: Sun Dec 04, 2005 7:27 pm Post subject: |
|
|
Indeed, queston 10 is the most tricky. The rest simply test your "reading and memory".
But how come the last question answer is none of the above?
I thought (1+'1') gives you '11'. Then "1"+ '11' gives you "111"?
What's your explanation?
|
|
| Back to top |
|
 |
Singachea fourth grade
Joined: 19 Nov 2005 Posts: 258
|
Posted: Sun Dec 04, 2005 8:11 pm Post subject: |
|
|
| guitarman wrote: |
Indeed, queston 10 is the most tricky. The rest simply test your "reading and memory".
But how come the last question answer is none of the above?
I thought (1+'1') gives you '11'. Then "1"+ '11' gives you "111"?
What's your explanation? |
The correct answer is "150".
However, the process is not like what you mentioned above.
1 + '1' will give you 1 + 49 = 50 (not '11' because int> char)
"1" + (50) becomes "150"
NOTE: "1" + 1 + '1' is different from 1 + '1' + "1"
Last edited by Singachea on Sun Dec 04, 2005 11:17 pm; edited 3 times in total |
|
| Back to top |
|
 |
guitarman fourth grade
Joined: 04 Nov 2005 Posts: 728
|
Posted: Sun Dec 04, 2005 9:30 pm Post subject: |
|
|
Thank you for pointing the correct way. but, isn't it round bracket takes precedent over the Plus operator? If it does, the answer wouldn't be 111, would it?
|
|
| Back to top |
|
 |
Singachea fourth grade
Joined: 19 Nov 2005 Posts: 258
|
Posted: Sun Dec 04, 2005 11:15 pm Post subject: |
|
|
Hi sorry again, I didn't see what i wrote. The question is "1" + (1+ '1') , not "1" + 1 + '1'
|
|
| Back to top |
|
 |
|