Skip to content

Instantly share code, notes, and snippets.

@boobo94
Last active May 20, 2019 15:30
Show Gist options
  • Save boobo94/04d23ba5e1d3d82331213f9f2b20ee1f to your computer and use it in GitHub Desktop.
Save boobo94/04d23ba5e1d3d82331213f9f2b20ee1f to your computer and use it in GitHub Desktop.
Full-Stack Interview Questions

2. Design Pattern Questions

1.1. Answer: https://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93controller#Components - The model is the central component of the pattern. It is the application's dynamic data structure, independent of the user interface. It directly manages the data, logic and rules of the application. - A view can be any output representation of information, such as a chart or a diagram. Multiple views of the same information are possible, such as a bar chart for management and a tabular view for accountants. - The controller, accepts input and converts it to commands for the model or view.

  1. Answer: https://en.wikipedia.org/wiki/Object-relational_mapping

3. Programming Languages Questions

3.1. PHP

  1. 2

4. Database Questions

  1. Difference between View and table in sql A table contains data, a view is just a SELECT statement which has been saved in the database. The advantage of a view is that it can join data from several tables thus creating a new view of it.

5. HTTP Questions

  1. https://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html

6. Web Services Specific Questions

2.1. ("OK") Everything went ok. 2.2. ("Moved Permanently") Client triggered an action on the server that caused the URI of a resource to change. 2.3. ("Bad Request") A problem occurred on the client side. The entity-body, if any, is a error message. 2.4. ("Not Found") Client requested a URI that doesn't map to any resource. 2.5. ("Internal Server Error") A problem occurred on the server side. The entity-body, if any, is a error message.

General

  1. What version control systems have you used (Git, SVN etc.)?
  2. How do you go about testing your PHP?
  3. How do you choose a library / module / package ? Hint 1: Do you take a look if there's a documentation ? Hint 2: Do you take a look over its Github repository ? Hint 3: Do you take a look of there are issues opened and if there's some activity ?
  4. How do you solve a blocker ? For example let's say you encounter a problem in the current project and that's a big blocker and you don't know where is the problem ? How do you start to solve it ?
  5. What's the biggest problem faced on your projects and how did you solve it?
  6. How do you organize your code ? Hint 1: How do you name your folders ? Hint 2: How do you name your files ?
  7. When do you optimize your code?
  8. Do you heard about MVC (Model View Controller) ? What is that ?
  9. Do you prefer to work on a team or alone?
  10. Do you have experience with Linux ? What about Linux Console ?

Technical

PHP

  1. Do you know which is the difference between a constant and a variable ?
  2. Result of
floor(3.14)

Answer: 3

  1. What value is returned from the above statement?
echo join("", array_reverse(str_split("i'm a lasagna hog")));

Answer: "goh angasal a m'i"

  1. What is the value of count($array)?
$array = array();

array_push($array, 1);
array_push($array, 2);

Answer: 2

  1. What is the result of the two alerts functions?
$foo = "Hello";

function alert_a() {
	global $foo;

	$bar = " World";

	echo ($foo . $bar);
}

function alert_b() {
	$bar = " World";

	echo ($foo . $bar);
}

alert_a();
alert_b();

Answer:

alert_a() = Hello World alert_b() = E_NOTICE : type 8 -- Undefined variable: foo -- at line 15 World

SQL

  1. Do you know ?
  2. How do you choose a column to be indexed?

Answer: You'd like to index columns, that appear in WHERE clause or JOIN condition.

  1. Are you familiar with NoSQL databases? Which one ?

Answer: for example MongoDB

  1. Do you know what is an ORM (Object Relational Mapping) ?

Answer: Technique to convert query results of database into a Object Oriented way.

  1. Why do databases treat null as a so special case? For example, why does SELECT * FROM table WHERE field = null not match records with null field in SQL?

Answer: The correct syntax is where is null

HTTP

  1. Can you give me some examples of HTTP methods? And why are used commonly for?

Answer:

- GET = retrive some data
- POST = sent data to server
- PUT = update some data
- PATCH = update some data partially
  1. Common Server Response Codes

2.1. Describe server response code 200.

Answer: ("OK") Everything went ok. The entity-body, if any, is a representation of some resource.

2.2. Describe server response code 301.

Answer: ("Moved Permanently") Client triggered an action on the server that caused the URI of a resource to change.

2.3. Describe server response code 404.

Answer: ("Not Found") Client requested a URI that doesn't map to any resource.

2.4. Describe server response code 500

Answer: ("Internal Server Error") A problem occurred on the server side. The entity-body, if any, is a error message.

1. General Questions

  1. What version control systems have you used (Git, SVN etc.)?
  2. What is your preferred development environment? (what IDE, text editor do you use)
  3. Have you ever looked at the source code of the libraries/frameworks you use?
  4. Do you prefer to work on a team or alone? In the office or remotely ?
  5. What's the biggest problem faced on your projects and how did you solve it?
  6. Do you contribute to open-source ? ( Can you give us an example ? )
  7. What did you learn yesterday/this week?
  8. What SQL languages do you know or you interacted with?
  9. Are comments in code useful? Some say they should be avoided as much as possible, and hopefully made unnecessary. Do you agree?
  10. Which is your preffered programming language ? Why ?
  11. Where will you be in 10 years?
  12. If you could travel back in time, which advice would you give to your younger self?

2. Design Pattern Questions

  1. Do you know what is an MVC ? 1.1. Can you describe it quickly ?
  2. Do you know what is an ORM ?

3. Programming Languages Questions

3.1. PHP

  1. What is the value of count($array)?
$array = array();

array_push($array, 1);
array_push($array, 2);

4. Database Questions

  1. In which case would you use a document database like MongoDB instead of a relational database like MySQL or PostgreSQL?
  2. The difference between a view and a table ?

5. HTTP Questions

  1. What HTTP methods do you know ?

6. Web Services Specific Questions

  1. Have you created or managed some web service?
  2. What it's a status code user for ? 2.1. Describe server response code 200. 2.2. Describe server response code 301. 2.3. Describe server response code 400. 2.4. Describe server response code 404. 2.5. Describe server response code 500.
  3. How would you manage Web Services API versioning?

7. Security

  1. What is two factor authentication? How would you implement it in an existing web application?

Other questions

https://gist.github.com/boobo94/04d23ba5e1d3d82331213f9f2b20ee1f#file-questions-md https://github.com/tvandame/back-end-developer-interview-questions https://github.com/arialdomartini/Back-End-Developer-Interview-Questions#general https://gist.github.com/chenrui333/7f235d2d8a114d4cf34c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment