Vous êtes sur la page 1sur 54

aoutir medamine (aoutir.medamine@gmail.

com)
Campagne : Java / SQL Standard Langage(s) de programmation : Java, SQL Langage : Anglais Date : 27/09/2018

SCORE RANG DURÉE

26% 101 1H39


1 202 / 4 550 pts / 133 / 2H22

Java 31%
(822 / 2 630)

Connaissance du language 56%


(689 / 1 224)

Fiabilité 12%
(33 / 271)

Modèlisation 33%
(100 / 300)

Résolution de problèmes 0%
(0 / 835)

SQL 20%
(380 / 1 920)

Connaissance du language 23%


(360 / 1 560)

Modèlisation 33%
(20 / 60)

Résolution de problèmes 0%
(0 / 300)

1 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 1: Enum
Java 00:19 / 00:30 40 / 40 pts

Question

Given this code, what is true about it?

Réponse
Planet.MERCURY == Planet.MERCURY is true
Planet.MERCURY == Planet.VENUS is true
Planet.MERCURY.equals(Planet.MERCURY) is true

Résultat
Réponse correcte
Connaissance du language +40pts

2 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 2: Bitwise Operator: >>
Java 00:20 / 00:20 0 / 40 pts

Question
What is the result of 2 >> 1 ?

Réponse
0
1
2
3
4

Résultat
Réponse incorrecte
Connaissance du language +40pts

3 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 3: Object class
Java 00:07 / 00:20 20 / 20 pts

Question
public class A {}

Who is the parent class of A ?

Réponse
Object
Root
Class A has no parent class

Résultat
Réponse correcte
Connaissance du language +20pts

4 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 4: String buffers
Java 00:26 / 00:30 60 / 60 pts

Question
Type the name of a class belonging to the package java.lang which allows to concatenate efficiently
strings of characters.

Réponse
StringBuilder

Résultat
Réponse correcte
Connaissance du language +60pts

Réponse(s) correcte(s)
StringBuilder
StringBuffer
java.lang.StringBuilder
java.lang.StringBuffer

5 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 5: Hash table
Java 00:46 / 02:30 0 / 40 pts

Question
Among the following options, which class would you use to rewrite UsersService ?

Réponse
Stack
Vector
ArrayList
LinkedList
HashMap
HashSet

Résultat
Réponse incorrecte
Connaissance du language +40pts

6 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 6: Strings equality
Java 01:09 / 02:30 0 / 50 pts

Question
A.isFoo(String param) should return true if param is equal to the string "foo", false otherwise.

Implement A.isFoo(String param).

Réponse

1 // Java code below


2 class A {
3
4 static boolean isFoo(String param) {
5 if(param=="foo"){
6 return true;
7 }else{
8 return false;
9 }
10
11 }
12
13 }

Résultat
Use equals instead of the operator '=='
Connaissance du language +17pts

Still works if param is null


Fiabilité +33pts

7 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 7: Garbage collector
Java 00:20 / 00:20 40 / 40 pts

Question
The garbage collector ensures that there is enough memory to run a Java program.

Réponse
True
False

Résultat
Réponse correcte
Connaissance du language +40pts

8 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 8: Operation on integers
Java 00:10 / 00:30 20 / 20 pts

Question
int i1 = 5;
int i2 = 2;
int i3 = i1 / i2;

What is the value of i3?

Réponse
3
2.5
2
NaN

Résultat
Réponse correcte
Connaissance du language +20pts

9 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 9: Constant
Java 00:17 / 00:25 20 / 20 pts

Question
Which option is a valid constant declaration in Java?

Réponse
define("MAXSIZE", 100);
#define MAXSIZE 100
public static final int MAXSIZE = 100;
const int MAXSIZE = 100;

Résultat
Réponse correcte
Connaissance du language +20pts

10 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 10: Abstract class
Java 00:10 / 00:20 0 / 20 pts

Question
An abstract class can contain concrete methods.

Réponse
True
False

Résultat
Réponse incorrecte
Connaissance du language +20pts

11 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 11: Equals and hashcode
Java 00:11 / 00:20 40 / 40 pts

Question
If two objects are equals then they should have the same hashcode.

Réponse
True
False

Résultat
Réponse correcte
Connaissance du language +40pts

12 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 12: Simple boolean expression
Java 01:49 / 02:00 100 / 100 pts

Question
A.a(int i, int j) should return true if one of the arguments equals 1 or if their sum is equal to 1.

For example:
A.a(1, 5) returns true
A.a(2, 3) returns false
A.a(-3, 4) returns true

Réponse

1 // Java code below


2 class A {
3
4 static boolean a(int i, int j) {
5 int sum=i+j;
6 if(i==1 || j==1 || sum==1){
7 return true;
8 }else{
9 return false;
10 }
11 }
12
13 }

Résultat
Returns true if i or j equals 1, false otherwise
Connaissance du language +67pts

Returns true if i+j equals 1


Fiabilité +33pts

Problème de lisibilité de code détecté


Avoid unnecessary if..then..else statements when returning booleans

13 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 13: Bitwise Operators: |
Java 00:20 / 00:25 40 / 40 pts

Question
In a base 2 system (binary), what is the value of 01 | 11?

Réponse
00
01
10
11
100

Résultat
Réponse correcte
Connaissance du language +40pts

14 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 14: String object
Java 00:07 / 00:20 20 / 20 pts

Question
String s;

What is the value of s ?

Réponse
""
null
"\0"

Résultat
Réponse correcte
Connaissance du language +20pts

15 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 15: Counter synchronization
Java 01:53 / 02:00 100 / 100 pts

Question
Make Counter.increment() thread safe.

Réponse

1 class Counter {
2
3 private static int count = 0;
4
5 /**
6 * Increments count in a thread-safe manner.
7 */
8 public static int increment() {
9 synchronized(Counter.class){
10 count = count + 1;
11 }
12
13 return count;
14 }
15
16 }

Résultat
Counter is synchronized
Connaissance du language +100pts

16 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 16: Multiple inheritance
Java 00:19 / 00:20 0 / 20 pts

Question
A Java class can have more than one parent class.

Réponse
True
False

Résultat
Réponse incorrecte
Connaissance du language +20pts

17 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 17: Visibility of attributes
Java 00:11 / 00:20 20 / 20 pts

Question
Privates attributes are visible from subclasses.

Réponse
True
False

Résultat
Réponse correcte
Connaissance du language +20pts

18 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 18: Final method
Java 00:20 / 00:20 0 / 20 pts

Question
A method declared as final means...

Réponse
the method can't be overridden
the method returns a constant
it's impossible: it leads to a compilation error

Résultat
Réponse incorrecte
Connaissance du language +20pts

19 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 19: Multiple inheritance of interfaces
Java 00:17 / 00:30 40 / 40 pts

Question
public interface A extends B, C, D {}

This interface is correct if B, C and D are also interfaces.

Réponse
True
False

Résultat
Réponse correcte
Connaissance du language +40pts

20 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 20: Secure closure of an I/O stream
Java 01:49 / 05:00 0 / 300 pts

Question
StreamPrinter.print(Reader reader) is not robust.

Improve StreamPrinter.print(Reader reader).

Réponse

1 import java.io.IOException;
2 import java.io.Reader;
3
4 /**
5 * This class defines a stream printer.
6 */
7 class StreamPrinter {
8
9 /**
10 * Reads from the given reader and print to stdout.
11 */
12 void print(Reader reader) throws IOException {
13 int code = reader.read();
14 while (code != -1) {
15 System.out.print((char) code);
16 code = reader.read();
17 }
18
19 reader.close();
20 }
21
22 }

Résultat
The stream is closed in case of exception.
Connaissance du language +100pts

The stream is closed in case of error.


Connaissance du language +100pts

The exception is still thrown to the caller.


Fiabilité +100pts

21 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 21: Bitwise Operators: &
Java 00:12 / 00:20 40 / 40 pts

Question
In a base 2 system (binary), what is the value of 0001 & 0001 ?

Réponse
0010
0000
0001

Résultat
Réponse correcte
Connaissance du language +40pts

22 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 22: Interfaces
Java 00:07 / 00:20 40 / 40 pts

Question
In Java 8, interfaces can contain concrete methods.

Réponse
True
False

Résultat
Réponse correcte
Connaissance du language +40pts

Question 23: Exception


Java 04:47 / 05:00 82 / 200 pts

Question
Update the code by implementing the following rules: If an exception is thrown by s.execute() then call c.
rollback() and propagate the exception, otherwise call c.commit() In any circumstances, c.close() must be
called before leaving the method a(Service s, Connection c)

23 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 class A {
2
3 /**
4 * Executes the service with the given connection.
5 */
6 void a(Service s, Connection c) {
7 // update this code
8 s.setConnection(c);
9 try{
10 s.execute();
11 c.commit();
12 }catch(Exception e){
13 e.printStackTrace();
14 c.rollback();
15 }
16 c.close();
17
18 }
19
20 }
21
22 interface Service {
23 void execute() throws Exception;
24 void setConnection(Connection c);
25 }
26
27 interface Connection {
28 void commit();
29 void rollback();
30 void close();
31 }

Résultat
Correct behavior in case of no exception
Connaissance du language +56pts

Use a finally block


Connaissance du language +65pts

Exception is re-thrown
Connaissance du language +53pts

Rollback and close on exception


Connaissance du language +26pts

24 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 24: Polymorphism
Java 02:18 / 02:30 0 / 60 pts

Question
let's define 2 classes:

class A {
int f(A a) {
return 1;
}
}

class B {
int f(A a) {
return 2;
}

int f(B b) {
return 3;
}
}

and the following main:

public static void main(String args[]) {


A a = new A();
A ab = new B();
B b = new B();

System.out.print(ab.f(a));
System.out.print(ab.f(ab));
System.out.print(ab.f(b));

what is the output produced?

25 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse
233
223
222
123

Résultat
Réponse incorrecte
Connaissance du language +60pts

26 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 25: From the fruit we know the tree
Java 24:56 / 25:00 0 / 300 pts

Question
A tree is composed of nodes which follow these rules:
A node holds a value corresponding to an integer. Except for the root node of the tree, a node is always
referenced by only one other node. A node has no more than two children. They are called left child
and right child. If a node has no right or left child, the corresponding reference is null. All the
descendants to the left of a node are smaller than the node and all the descendants to the right of the
node are greater than the node.
Here is an example of such a tree (the root node holds the integer 9):

Fig. 1
To simplify things, we combine everything into a single class named Node. The height of the tree is
between 0 and 100 000 nodes (the height of a tree is the length of the path from the root to the
deepest node in the tree). Question: Implement a new Node's method named find(int v) which returns
the node holding the value of v. If the node doesn't exist then find should return null. Important note:
Try to save memory (RAM) space. To test your solution you can use two examples of tree: The variable
small corresponds to the root node of the tree from Fig. 1. The variable large corresponds to the root
node of a tree of height 100 000 nodes. The deepest node holds 0.

27 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 class Node {
2
3 // keep these fields
4 Node left, right;
5 int value;
6 Node find(int v){
7 if(left!=null && right!=null){
8 if(left.value==v){
9 return left;
10 }else if(right.value==v){
11 return right;
12 }else{
13 while(left.value!=null || right.value!=null){
14 if(left.value==v){
15 return left;
16 }else if(right.value==v)
17 return right;
18 else{
19 break;
20 }
21 }
22
23
24 }
25 }
26
27 }
28
29 }

Résultat
Results are correct with a 'small' tree
Résolution de problèmes +90pts

Results are correct with a 'large' tree


Résolution de problèmes +195pts

If the node doesn't exist, then null is returned


Fiabilité +15pts

28 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 26: File finder
Java 08:21 / 30:00 0 / 600 pts

Question
You don’t remember where you saved the file universe-formula. The only thing you remember about
this file is you put it somewhere in a sub-folder of /tmp/documents.

Implement the method String locateUniverseFormula() to locate universe-formula and then return the
absolute path of the file (from the file system root). /tmp/documents can contain nested sub-folders
and universe-formula can belong to any one of them. If universe-formula cannot be found, then your
program should return null. Example :
locateUniverseFormula() returns /tmp/documents/a/b/c/universe-formula if universe-formula is found
inside the folder /tmp/documents/a/b/c.

Réponse

1 import java.io.*;
2
3 class A {
4
5 /**
6 * Locates the universe-formula file.
7 */
8 static String locateUniverseFormula() {
9
10 }
11
12 }

Résultat
universe-formula is found
Résolution de problèmes +350pts

null is returned when universe-formula does not exist in /tmp/documents


Fiabilité +50pts

The algorithm stops to process as soon as universe-formula is found


Résolution de problèmes +200pts

29 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 27: The Liskov Substitution Principle (LSP)
Java 00:28 / 00:45 40 / 40 pts

Question
Derived classes must be substitutable for their base classes.

Réponse
True
False

Résultat
Réponse correcte
Modèlisation +40pts

30 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 28: Design pattern 01
Java 00:50 / 00:50 40 / 40 pts

Question
public class A {

private A() {}

private static class AHolder {


private static final A INSTANCE = new A();
}

public static A getInstance() {


return AHolder.INSTANCE;
}
}

If you know the design pattern used in this piece of code, type its name in the text field (1 word only).

Réponse
Singleton

Résultat
Réponse correcte
Modèlisation +40pts

Réponse(s) correcte(s)
Singleton
Singleton Pattern

31 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 29: The Dependency Inversion Principle (DIP)
Java 00:13 / 00:45 20 / 20 pts

Question
Abstractions should not depend upon details. Details should depend upon abstractions.

Réponse
True
False

Résultat
Réponse correcte
Modèlisation +20pts

Question 30: Abstraction


Java 04:00 / 08:00 0 / 200 pts

Question
Try to improve the code displayed in the answer editor by keeping the current behavior of the program.

32 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 abstract class Animal { }


2
3 class Dog extends Animal {
4 String name;
5
6 /**
7 * Creates a new dog with the given name.
8 */
9 Dog(String name) {
10 this.name = name;
11 }
12
13 String getName() {
14 return name;
15 }
16 }
17
18 class Cat extends Animal {
19 String name;
20
21 /**
22 * Creates a new cat with the given name.
23 */
24 Cat(String name) {
25 this.name = name;
26 }
27
28 String getName() {
29 return name;
30 }
31 }
32
33 class Application {
34
35 /**
36 * @return the name of the given animal
37 */
38 static String getAnimalName(Animal a) {
39 String name = null;
40 if (a instanceof Dog) {
41 name = ((Dog) a).getName();
42 } else if (a instanceof Cat) {
43 name = ((Cat) a).getName();
44 }
45
46 return name;
47 }
48 }

33 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Résultat
Behavior is still correct and Animal.getName is used
Modèlisation +160pts

Application.getAnimalName is updated to use Animal.getName


Fiabilité +40pts

Question 31: Interface vs. implementation


Java 00:14 / 00:30 0 / 40 pts

Question
Among these method declarations, which is usually the preferred one?

Réponse
public ArrayList getOrders()
public Vector getOrders()
public List getOrders()

Résultat
Réponse incorrecte
Modèlisation +40pts

34 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 32: SQL - NOT NULL
SQL 04:16 / 05:00 0 / 200 pts

Question

Modify the query to list the customers having a zipcode equal to 75000 or 34000 and who have a
birthdate defined.

Only output the LASTNAME and FIRSTNAME columns in that order.

Example of output:

--------------------------
| LASTNAME | FIRSTNAME |
--------------------------
| RIVER | John |
| JACKSON | Elizabeth |
| PUTTER | James |
--------------------------

35 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT firstname,lastname
3 FROM customer where zipcode='75000' or zipcode='34000' and birth_date is not null

Résultat
Use of "not null"
Connaissance du language +200pts

36 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 33: SQL - HAVING
SQL 05:00 / 05:00 0 / 200 pts

Question

Modify the query to list the number of customers per city. Only list the cities where the number of
customers within the city is two or more.

Only output the CITY and CUSTOMER_COUNT columns in that order.

Output example:

--------------------------------
| CITY | CUSTOMER_COUNT |
--------------------------------
| Boston | 8 |
| New Delhi | 2 |
--------------------------------

37 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT city as "CITY",count(customer_id) as "CUSTOMER_COUNT"
3 FROM customer group by city

Résultat
Use of "having"
Connaissance du language +200pts

Question 34: SQL - INSERT


SQL 00:12 / 00:30 20 / 20 pts

Question
Which SQL command would you use to add a row in a table of a database?

Réponse
INSERT
ADD
UPDATE
MORE

Résultat
Réponse correcte
Connaissance du language +20pts

38 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 35: SQL - NOT EXISTS
SQL 05:00 / 05:00 0 / 200 pts

Question

Modify the query to select only the customers with no associated purchase orders.

Only output the CUSTOMER_ID column.

Example of output:

---------------
| CUSTOMER_ID |
---------------
| 8 |
| 5 |
---------------

39 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT customer_id
3 FROM customer
4 LEFT JOIN PURCHASE_ORDER ON c.customer_id=PURCHASE_ORDER.customer_id
5 WHERE PURCHASE_ORDER.customer_id is null

Résultat
Use of "not exists" or "not in"
Connaissance du language +200pts

40 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 36: SQL - GROUP BY
SQL 05:00 / 05:00 0 / 300 pts

Question

Modify the query to list the number of products per product category.

Product categories with no products are not to be listed.

Only output the CATEGORY_NAME (product_category.name) and PRODUCT_COUNT columns in that


order.

Example of output:

---------------------------------
| CATEGORY_NAME | PRODUCT_COUNT |
---------------------------------
| Books | 3 |
| Automotive | 2 |
| High-tech | 8 |
---------------------------------

41 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT name as "CATEGORY_NAME", count(product_id) as "PRODUCT_COUNT"
3 FROM PRODUCT_CATEGORY GR

Résultat
Use of "group by"
Connaissance du language +300pts

42 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 37: SQL - OUTER JOIN
SQL 06:00 / 06:00 0 / 300 pts

Question

Modify the query to list all the products and their associated categories if they have one. Return no
value (null) as the category otherwise.

Output only the PRODUCT_NAME and CATEGORY_NAME columns in that order.

Example of output:

-----------------------------------------
| PRODUCT_NAME | CATEGORY_NAME |
-----------------------------------------
| ProForm 6.0 RT | Fitness |
| Wilwood 260-11179 | Automotive |
| HC-SR04 | null |
-----------------------------------------

43 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 select p.name as "PRODUCT_NAME",cc.name as ""
3 from product p
4 inner join product_category cc on cc.product_category_id = p.product_category_id

Résultat
Use of outer joins
Connaissance du language +300pts

44 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 38: SQL - DISTINCT
SQL 02:21 / 05:00 100 / 100 pts

Question

Modify the query to get the list of customers' cities. The list should contain no duplicates and should be
sorted alphabetically.

Only output the CITY column.

Example of output:

---------------
| CITY |
---------------
| Istanbul |
| Montpellier |
| Tokyo |
---------------

45 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT distinct(city) as "CITY"
3 FROM customer order by city asc

Résultat
Use of "distinct", "order by"
Connaissance du language +100pts

Question 39: SQL - DELETE


SQL 00:08 / 00:30 20 / 20 pts

Question
What SQL command should be used to remove a row from a table in a database?

Réponse
REMOVE FROM table WHERE...
UPDATE table REMOVE WHERE...
DELETE FROM table WHERE...
DROP FROM table WHERE...

Résultat
Réponse correcte
Connaissance du language +20pts

46 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 40: SQL - LIKE
SQL 03:44 / 05:00 200 / 200 pts

Question

Modify the query to select only the customers having their lastname starting with 'W', sorted
alphabetically by lastname then firstname. Only output the lastname and firstname columns.

Only output the columns LASTNAME and FIRSTNAME in that order.

Example of output:

------------------------
| LASTNAME | FIRSTNAME |
------------------------
| WHITTARD | Bill |
| WILLIAMS | John |
------------------------

47 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT lastname as "LASTNAME",firstname as "FIRSTNAME"
3 FROM customer
4 where lastname like 'W%' order by (lastname,firstname)

Résultat
Use of "like", "order by"
Connaissance du language +200pts

Question 41: SQL - DROP


SQL 00:11 / 00:45 20 / 20 pts

Question
What SQL command is used to remove a table from database?

Réponse
DELETE table
TRUNCATE table
DROP table
REMOVE table

Résultat
Réponse correcte
Connaissance du language +20pts

48 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 42: SQL - Multiple joins
SQL 08:00 / 08:00 0 / 300 pts

Question

Modify the query to select only the ids of customers having purchased at least one product in the
"Books" or "Garden" category. Output should have no duplicates and should be sorted in ascending
order.

Only output the CUSTOMER_ID column.

Example of output:

---------------
| CUSTOMER_ID |
---------------
| 0 |
| 5 |
---------------

49 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Réponse

1 -- SQL request(s) below


2 SELECT customer_id as "CUSTOMER_ID"
3 FROM customer
4 inner join purchase_order.customer_id=customer.customer_id
5 inner join purchase_order.order_id=order_product.order_id
6 inner join order_product.product_id=product.product_id
7 inner join product.product_category_id=product_catego

Résultat
All tables joined
Résolution de problèmes +300pts

50 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 43: SQL - Primary key
SQL 00:24 / 01:00 0 / 40 pts

Question
Select the proposals which are true when dealing with a "Primary key" column.

(multiple responses possible)

Réponse
It cannot contain any duplicate values
It can contain the NULL value
It cannot be a foreign key
It can have a character data type (like "VARCHAR")

Résultat
Réponse incorrecte
Modèlisation +40pts

51 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Question 44: SQL - Foreign key #1
SQL 00:28 / 01:00 20 / 20 pts

Question

From the above database schema, select what best describes the column "customer_id" of the
PURCHASE_ORDER table.

Réponse
Primary key
Index
Blob
Foreign key

Résultat
Réponse correcte
Modèlisation +20pts

52 / 54
aoutir medamine (aoutir.medamine@gmail.com)
53 / 54
aoutir medamine (aoutir.medamine@gmail.com)
Glossaire

Connaissance du langage

La mesure de cette compétence permet de déterminer lexpérience du candidat dans la pratique dun langage de
programmation. Privilégiez cette compétence si, par exemple, vous recherchez un développeur qui devra être
rapidement opérationnel.

Design

Cette mesure fournit une indication sur la capacité du candidat à appliquer des solutions standard pour résoudre des
problèmes récurrents. Un développeur ayant un bon niveau dans cette compétence augmentera la qualité
(maintenabilité, évolutivité) de vos applications. Cette compétence ne dépend pas spécifiquement dune technologie.
Privilégiez cette compétence si, par exemple, vous recherchez un développeur qui sera amené à travailler sur les
briques qui structurent vos applications, à anticiper les besoins de demain pour développer des solutions pérennes.

Résolution de problèmes

Cette compétence correspond aux aptitudes du candidat à comprendre et à structurer son raisonnement pour trouver
des solutions à des problèmes complexes. Cette compétence ne dépend pas spécifiquement dune technologie.
Privilégiez cette compétence si, par exemple, vos applications ont une composante technique importante (R&D,
innovation).

Fiabilité

La fiabilité caractérise la capacité du candidat à réaliser des solutions qui prennent en compte les cas particuliers. Plus
cette compétence est élevée, plus vos applications sont robustes (moins de bugs).

54 / 54
aoutir medamine (aoutir.medamine@gmail.com)

Vous aimerez peut-être aussi