Explain why type assertion is used in go language?
Answer / Ashish Ghildiyal
Type assertion in Go allows the programmer to check and manipulate values of a specific type within an interface{}. It is used when you want to check or extract the concrete underlying value behind an interface{}.
| Is This Answer Correct ? | 0 Yes | 0 No |
How we can print type of a variable in go programming?
What is default value of a global and local variable in go?
What is function closures in go pragramming?
How you to access command line arguments passed to a go program?
Write the syntax to create a function in go programming language?
What is go interfaces?
Is it recommended to use global variables in a program that implements goroutines?
How you can write multiline strings in go?
Is go (golang) a case sensitive language?
What are methods in go?
What is goroutine?
What is a pointer in go?