Let’s look at a few sample questions one by one.
– Sample questions from the React JS stack test
Question 1: Give the following code… class SampleComponent extends React.Component {
handleClick(id) {
//do stuff with id
}
render() {
//…
}
}
What is the correct way to pass the parameter id to handleClick?
Answers (Choose one)
a. <button onClick={() => this.handleClick(id)} />
b. <button onClick={this.handleClick(id)} />
c. <button onClick={this.handleClick.bind(id)} />
d. <button onClick={this.handleClick.bind(this, id)} /> .
Question 2: Which of the following are pointer events that are available in ReactDOM?
Answers (Choose one)
- onPointerTouchMove
- onGotPointerCapture
- onLostPointerCapture
- onPointerTouchUpOutside
- onPointerTouchUpInside
– Sample questions from the React Hooks stack test
Question 1: You are using React Hooks to develop a Turing system. How can you fetch data with it?
Answers (Choose one)
- Call API to fetch data in useState hook
- Using useEffect Hook to fetch data
- Call API in useReducer
- Using useLayoutEffect(() => {…}, []) to fetch data
Question 2: You are a ReactJS developer at Turing. Please point out the correct statement about useState in React Hooks.
Answers (Choose one)
- useState is a Hook that lets you add React state to function components
- argument in useState is the initial state
- useState returns is pair containing the current state and a function to update it
- useState is a function
- All of above
– Sample questions from the Python stack test
Question 1: What is the output of the following Python code snippet?
z=set(‘abc’)
z.add(‘san’)
z.update(set([‘p’, ‘q’]))
print(z)
Answers (Choose one)
- {‘abc’, ‘p’, ‘q’, ‘san’}
- {‘a’, ‘b’, ‘c’, [‘p’, ‘q’], ‘san}
- {‘a’, ‘c’, ‘c’, ‘p’, ‘q’, ‘s’, ‘a’, ‘n’}
- {‘a’, ‘b’, ‘c’, ‘p’, ‘q’, ‘san’}
Question 2: You are a Python developer at Turing. You want to merge two list l1 = [1,2,3,4] l2 = [5,6,7]
Answers (Choose one)
- result = l1 + l2
- result =extend(l1,l2)
- result =l1.extends(l2)
- l1.append(l2)
– Sample questions from the Node JS stack test
Question 1: Which of the following is true about the EventEmitter.on the property?
Answers (Choose one)
- The .on property is used to fire events.
- The .on property is used to bind a function with the event.
- The .on property is used to locate an event handler.
- None of these
Question 2: Although JavaScript is single-threaded, what allows you to perform non-blocking I/O operations by offloading operations to the system kernel whenever possible?
Answers (Choose one)
- REPL
- Timers
- Poll
- Process
- Event Loop
– Sample questions from the Django stack test
Question 1: You are building a Turing system with Django. Following source code urlpatterns = [ url(r’^admin/’, admin.site.urls), url(‘turing/’, include(‘turing.urls’)), url(‘companies/’, include(‘companies.url’)) ] What happening if skipping the trailing/splash?
Answers (Choose one)
- Syntax error
- Django will display 404 page
- Django will match with Turing/ pattern
- None of above
Question 2: Which validator is not the default Password Validators in Django?
Answers (Choose one)
- MinimumLengthValidator
- NumericPasswordValidator
- MaximumLengthValidator
- CommonPasswordValidator
– Sample questions from the DevOps stack test
Question 1: Which Git command changes where the HEAD pointer points and modifies the contents of the working directory?
Answers (Choose one)
- checkout
- merge
- pull
- mv
- none of the above
Question 2: Given the text below: “Whether you think you can or think you can’t – you are right.” — Henry Ford (1863 – 1947) Using the regex pattern you.*n , gives you:
Answers (Choose one)
- you think you can or think you can
- you think you can or think you can’t
- you think you can
- you can or think you can
– Sample questions from the iOS Swift stack test
Question 1: let x: String?? = .some(nil)
let outputX = (x ?? “inner”) ?? “outer”
let y: String?? = nil
let outputY = (y ?? “inner”) ?? “outer”
let string = “\(x) \(y) \(outputX) \(outputY)”
What is the value of a string?
Answers (Choose one)
- nil inner inner
- nil nil inner inner
- Optional(nil) nil inner inner
- Optional(nil) nil outer inner
- error: member ‘some’ in ‘String??’
Question 2: extension CGSize { mutating func scale(by f: CGFloat) { width *= f height *= f } } let s = CGSize(width: 100, height: 100) s.scale(by: 2) s.scale(by: 2) s.width += 100 What is the value of s?
Answers (Choose one)
- (100.0, 100.0)
- (200.0, 200.0)
- (400.0, 400.0)
- (500.0, 400.0)
- Compiler error
– Sample questions from the WPF stack test
Question 1: What is the correct answer about the target of WPF transformations?
Answers (Choose one)
- On skewing
- Only scaling
- Only rotation
- translate
- rotation, scaling and skewing
Question 2: Which of the following is a correct statement about Exception in WPF?
Answers (Choose one)
- Exceptions can transfer the flow of a program from one part to another
- Exceptions should be used as a “last line of defense” for user error.
- You can handle the global exceptions by Application.DispatcherUnhandledException
- All of above
– Sample questions from the Spring Boot stack test
Question 1: Which of the following is not TRUE about Spring Boot Devtools?
Answers (Choose one)
- By default, DevTools applies properties suitable to a development environment.
- Applications using DevTools restart whenever a file on the classpath changes
- The spring-boot-devtools module is automatically disabled if the application runs in production
- The spring-boot-devtools is a tool that monitors the health of a system that contains CPU, RAM, metric… information
- Static resources, including view templates, don’t set off a restart if the LiveReload extension is installed in the browser to interact with the embedded LiveReload server that DevTools contains
Question 2: You are a developer at Turing. You need to register a custom Auto-Configuration. How can you do it?
Answers (Choose one)
- Using @Component annotation. It will auto-load when the application started.
- Using @EnableAutoConfiguration annotation.
- Having auto-configuration class fully-qualified name listed under the EnableAutoConfiguration key in the META-INF/spring.factories file
- All of above
– Sample questions from the Golang stack test
Question 1: Fill in the blanks for lines marked with A and B, to ensure that the printed output is “foo” package main type S struct { m string } func f() *S { return __ // A } func main() { p := __ // B print(p.m) //print “foo” }
Answers (Choose one)
- “foo”, f()
- &S{“foo”}, f()
- *S{“foo”}, f()
- Compilation error
Question 2: Assume x is declared and y is not declared. Which of the following clauses are correct? Choose all the correct answers.
x, _ := f() //A x, _ = f() //B x, y := f() //C x, y = f() //D
Answers (Choose one)
- A
- B
- C
- D
How many tech stack tests can a developer appear for?
- One
- Two to four
- Five to seven
- More than seven
Vote