Skip to content

core-go/go-interview-questions

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

go-interview-questions

General & Experience

  • Can you briefly describe the recent Golang project you worked on? What was your role and the main challenges you faced?
  • What do you like most about developing in Golang compared to other languages you might know?

Golang Core Concepts

  • Can you explain the difference between a slice and an array in Go? When would you use one over the other?
  • How do Goroutines work in Go? Can you describe a situation where you used them effectively?
  • What’s your understanding of channels in Go? Can you give a practical example of how you've used them?
  • What happens when you use the defer keyword in Go? Can you explain its use case with an example?
  • What’s the difference between make and new in Go? When would you use each?

Web Development & APIs

  • Have you developed any REST APIs using Go? Which framework or library did you use (Gin, Echo, Fiber, etc.), and why?
  • How do you handle request validation in your APIs? Can you share an example of how you structured it?
  • Can you explain how you implement middleware in Go? Maybe describe a middleware you have written.
  • What’s your approach to error handling in a web application? Do you follow any best practices?

Database Integration

  • What database(s) have you worked with in your Golang projects? How did you connect to them (libraries, tools)?
  • How do you perform CRUD operations in Go? Can you describe a typical pattern or structure you use?
  • Have you worked with transactions in Go’s database/sql package? Can you explain how you handle transactions?

Concurrency & Performance

  • Have you encountered race conditions in Go? How did you detect and fix them?
  • Have you used worker pools or implemented background jobs in Go? Can you describe how you did that?

Testing & Debugging

  • How do you write unit tests for your Golang code? Have you used any mocking libraries?
  • Can you explain what table-driven testing is in Go, and why it’s useful?
  • Have you ever used tools like the Go race detector or pprof? In what situations?

️ Project Structure & Best Practices

  • How do you usually structure your Golang projects (folders, packages)?
  • How do you manage environment variables and application configurations in Go?
  • Do you follow any code conventions or best practices to write clean and maintainable Go code?

Security & DevOps

  • Have you implemented authentication and authorization (like JWT) in Go? Can you explain how you did it?
  • Do you have experience containerizing your Go applications with Docker? How do you optimize your Dockerfile for a Go app?

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published