Win a copy of Classic Computer Science Problems in Swift this week in the iOS forum!

A. Costa

+ Follow
since Mar 30, 2016
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by A. Costa

Good to know, thank you all for your answers.
I will take a look to the autocommit stuff asap. Any other topic that I should know before facing the exam but it's not in your book?

Thanks a million!
Hello everybody,

I found some questions related to JDBC in enthuware exams that I guess they are not in the examen's scope anymore (SE 8):

- con.setAutoCommit(false)
- prepared statements
- callable statements
- ResultSetMetaData

does anybody who has taken the exam lately ran into this kind of questions or something that shouldn't be in the scope?
Would you mind to explain a little bit better why the example of the> Double.valueOf(x)) compiles? I didn't grasp it.
As far as I know, if there is no braces and the "body" of the lamba expression is just one line, you will have as a return the body expression, so in this case Double.valueOf(x) should return a Double and the forEach shouldn't compile.

Could you explain it further?

Than you all! 
Good morning,

I'm using this old post because I might have found an errata in the same page. 
In the #7, the answer is A, but I think that the code doesn't compile due to toRealPath() and File.isSameFile(path1, path2).  These methods trow an IOException but it's not handled in any way.
Is this an errata or am I missing something here?

Than you!
Good morning,

Correct me f I¡m wrong but I think that the answer to the Q18 question should be E (A SQLException is thrown) instead of A (Anna) because the ResultSet is not one of the Scrollable types and that should throw the Exception in the rs.absolute(0) line.

Thank you!
Yes, I just misread that. Thanks a million.
2 years ago
Could anyone explain me why B is not correct as well? "Change doStuff in Great to throw FileNotFoundException and IllegalArgumentException." That would fix the overriding problem with doStuff method in Amazing class and it wouldn't get a compile error in main method because it throws an IOException wich is a parent of FileNotFoundException. What am I not getting right here?

Sorry for reopening a thread.

2 years ago
Do you mind explaining me why onw of the answers for type 6 is the B one? How could the acces modifier of a method in the same class change result of it?
If I had to pick one (besides A) I would go for C, but it says "runtime Exception" and I think that the executin of the code would throw an OutOfMemoryError not a runtime exception...but I'm not sure.

Could someone explain it?

Thanks a milion!