Go Assessment Help

Hi I am trying to get an assessment in Golang and I would like to share with you some questions I am having some doubts about the answers:
Yhank in advance!

  1. Which is the best way to append a new element in the array?
    - create the same size array and append to it
    - not possible to add a new item
    - create a slice and append in it
    - None of the above

  2. Is it possible to get an error value from a blank identifier?
    - Yes
    - No

  3. Can we directly pass the structure from client to server in go?

    • No, we cannot pass struct directly
    • Yes, we can pass struct directly
      • Non of the above
  4. If you want to send logging messages to a file or to a network service without having to write your
    own logging system then:

    • use default logger
      -initialize a new log.Logger and send log messages to that
      -avoid new loggers systems
      -none of the above
  5. Does concurrency achieve through multi core processor?

    • Yes
      • No
  6. What is an easily accesible method to provide versioned APIs?
    - Use version control tool

    • Provide the API version in the REST API URL
    • Use extension
      • Both a and b
  7. Which go package will best suit for HTTP url matching with exact client request?

    • Http package
    • Regx package
    • String package
      • Fmt package
  8. When the application get exit?

    • Error
    • Panic
    • Fatal error
    • Both a and b
    • Both b and c
    • Both a and c
      • All a, b, c
  9. What is the use of Blank identifiers in ‘for’ loop?

    • To avoid Compilation error
    • To avoid Run time error
    • Don’t want to get the index value of the elements
      • None of the above
  10. Which of the below Statement is correct about Fully Public Acces Specifiers in Go?
    a)
    Type user Struct
    {
    Name String,
    ID int
    }

    b)
    Type User Struct
    {
    Name String,
    ID int
    }

    c)
    Type User Struct
    {
    name String,
    id int
    }

    d)
    None of the above

  11. What is the correct way to append a new element in the array?

    • make([]T, len, cap)[]T
    • make(T, len, cap)[]T
    • make([]T, len, cap)T
      • None of the above

Which answers do you suggest?

I selected the following but I didnt pass the test:

  1. Which is the best way to append a new element in the array?
  • create the same size array and append to it
  • not possible to add a new item <------
  • create a slice and append in it
  • None of the above
  1. Is it possible to get an error value from a blank identifier?
  • Yes
  • No <------
  1. Can we directly pass the structure from client to server in go?
    • No, we cannot pass struct directly <------
    • Yes, we can pass struct directly
    • Non of the above
  2. If you want to send logging messages to a file or to a network service without having to write your
    own logging system then:
    • use default logger <------
    -initialize a new log.Logger and send log messages to that
    -avoid new loggers systems
    -none of the above
  3. Does concurrency achieve through multi core processor?
    • Yes
    • No <------
  4. What is an easily accesible method to provide versioned APIs?
  • Use version control tool <------
    • Provide the API version in the REST API URL
    • Use extension
    • Both a and b
  1. Which go package will best suit for HTTP url matching with exact client request?
    • Http package <------
    • Regx package
    • String package
    • Fmt package
  2. When the application get exit?
    • Error
    • Panic
    • Fatal error
    • Both a and b
    • Both b and c <------
    • Both a and c
    • All a, b, c
  3. What is the use of Blank identifiers in ‘for’ loop?
    • To avoid Compilation error
    • To avoid Run time error
    • Don’t want to get the index value of the elements <------
    • None of the above
  4. Which of the below Statement is correct about Fully Public Acces Specifiers in Go?
    a)
    Type user Struct
    {
    Name String,
    ID int
    }
    b)
    Type User Struct <------
    {
    Name String,
    ID int
    }
    c)
    Type User Struct
    {
    name String,
    id int
    }
    d)
    None of the above
  5. What is the correct way to append a new element in the array?
    • make([]T, len, cap)[]T
    • make(T, len, cap)[]T
    • make([]T, len, cap)T
    None of the above <------

Which of your answers were correct, which were wrong?

Unfortunately the Test does not give you the wrong answers only passed or not passed