9/10. Got Nr5 wrong, what's the right answer?
1. Compiler
South Africa’s biggest forum. Discuss, discover, and connect with thousands of members.
9/10. Got Nr5 wrong, what's the right answer?
9/10. Got Nr5 wrong, what's the right answer?
90%
The … translates an entire program into machine language before execution
I said interpreter, as that's exactly what an interpreter does.
A compiler could be compiling into machine code, but not necessarily so. Consider a java compiler, which compiles into byte code, which itself is then, yes, interpreted by the JVM into instructions the OS can understand & execute. Hence (among other responsibilities), the JVM fulfills the role of "interpreter".
So, while a compiler may or may not be translating into machine code, an interpreter (usually) always is.
The expected answer is compiler. The more correct answer is interpreter.
The entire program into machine language. Interpreters translate source code/byte code into machine code line by line and execute immediately. That alone rules out interpreters. Multiple choice is also about choosing the most correct option when technicalities arise.
The most correct option is compiler.
Good point, though it doesn't say "... before execution of any part of the program", which still leaves interpreter as the most correct answer.
As mentioned, a compiler may not even be translating into machine code at all, which, at best, makes it a very dubious answer.
"some compilers translate into machine language" sure, I can live with that.
"compilers translate into machine language"... ehhhh, no, no, not all of them.
It's like saying "animals are warm-blooded". Sure, some of them are, but some of them are not.
are you in HR?
I'm gonna have to disagree with you.
Yes it does. "The … translates an entire program into machine language before execution". By translating the entire program into machine code before execution you are translating before executing any part of the program.
The question is: "The … translates an entire program into machine language before execution".
Some (most?) compilers do exactly that, but interpreters do not translate the entire program into machine code before execution. Thus the most correct answer is compiler.
Explain the average then
Yup it will. The question is poorly phrased by including the "needed."A switch will still work, but meh, whatever
You mean the best one for the job? That's not what the ambiguous question asks.I don't understand why people are arguing about routers VS switches.
Routers route traffic between networks. Yes you get layer 3 switches, but why not choose the obvious answer?
While I agree with you on that it's not a hard rule and they do have a point. An interpreter may translate the entire program into machine code just as a compiler may not compile to machine code. So both answers are somewhat correct while neither are completely correct. I think it's a stupid question to include both.I'm going to have to disagree with you.
Yes it does. "The … translates an entire program into machine language before execution". By translating the entire program into machine code before execution you are translating before executing any part of the program.
The question is: "The … translates an entire program into machine language before execution".
Some (most?) compilers do exactly that, but interpreters do not translate the entire program into machine code before execution. Thus the most correct answer is compiler.
Well "between networks" implies different networks. Using a switch would make it the same network. No one uses hubs and "hot spot" is more advertising than IT.100%
Some questions here are tricky, like #2, #6, #9.
In general, difficult for those who haven't studied for IT, or never dealt with computer hardware assembly and setup, or had business with programming.