Go Online Quiz


Advertisements


Following quiz provides Multiple Choice Questions (MCQs) related to Go. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.

Questions and Answers

Q 1 - Is Go a case sensitive language?

A - yes

B - no

Answer : A

Explanation

Yes! Go is a case sensitive programming language.

Q 2 - Which of the following is not a integer type in Go?

A - uint8

B - uint64

C - complex128

D - All of the above.

Answer : C

Explanation

complex128 is not a integer type.

Answer : C

Explanation

Both of the above options are correct.

Q 4 - Does Go supports function closures?

A - true

B - false

Answer : A

Explanation

Yes! function clousures are supported in Go. Functions closure are anonymous functions and can be used in dynamic programming.

Q 6 - Which of the following function returns the capacity of slice as how many elements it can be accomodate?

A - size()

B - len()

C - cap()

D - None of the above.

Answer : C

Explanation

cap() function returns the capacity of slice as how many elements it can be accomodate.

Q 7 - Which of the following terminates the for loop or switch statement and transfers execution to the statement immediately following the for loop or switch in Go?

A - break

B - continue

C - goto

D - None of the above.

Answer : A

Explanation

break terminates the for loop or switch statement and transfers execution to the statement immediately following the for loop or switch.

Q 8 - Go programming implementations use a traditional compile and link model to generate executable binaries.

A - false

B - true

Answer : B

Explanation

Go programming implementations use a traditional compile and link model to generate executable binaries.

Q 9 - The first line of the program package defines the package name in which a Go program should lie.

A - true

B - false

Answer : A

Explanation

The first line of the program package defines the package name in which a Go program should lie.

Q 10 - An lvalue may appear as either the left-hand or right-hand side of an assignment.

A - false

B - true

Answer : B

Explanation

An lvalue may appear as either the left-hand or right-hand side of an assignment.


go_questions_answers.htm

Advertisements
E-Books Store