Setf refers to set field?
Yes
No
View Answer
Correct Answer: A — Yes
Explanation:
The full form of setf is set field and it means that it sets the field with the value given.
5 practice sets · Page 1 of 1
Setf refers to set field?
Yes
No
Correct Answer: A — Yes
Explanation:
The full form of setf is set field and it means that it sets the field with the value given.
In multiple arguments in setf and setq, it prints ____
All the values
Only the first value
Only the last value
Numerically smallest value
Correct Answer: C — Only the last value
Explanation:
In the process of assigning values to multiple variables with setf and setq, the setf and setq prints only the last value assigned to a variable. It does not print all the values.
How many arguments do setf or setq can have in single braces?
2
4
28
Any even number of arguments.
Correct Answer: D — Any even number of arguments.
Explanation:
The setf and setq takes any number of arguments but the number must be even. Even is required because one of the two will be value taker and another one will be value giver. So, it always comes in a pair.
Choose the correct about Setf and Setq.
Setq can be used in place of setf but not vice versa
Setf can be used in place of setq but not vice versa
Both can be used in place of each other
Neither can be used in place of each other
Correct Answer: B — Setf can be used in place of setq but not vice versa
Explanation:
Setq is used only for symbols and setf is used for any data type, so Setf can be used in place of setq but setq cannot be used in place of setf.
What is the difference between setf and setq?
Setq is used for symbols only but setf can be used anywhere
No difference is there
Setf is used only for numbers but setq used anywhere
Setf is for lists and setq for numbers
Correct Answer: A — Setq is used for symbols only but setf can be used anywhere
Explanation:
Setq is used only for setting the values of symbols but setf can be used for anything. Setf can be used for setting value of any data-type and not only symbols.