Keyboard shortcuts
-
Navigation
- nNext font
- pPrevious font
-
Languages
- 1HTML
- 2CSS
- 3JavaScript
- 4Characters
-
Theme
- tToggle theme
-
Misc
- ?Toggle this keybaord shortcuts modal
At the 42 Piscine, exams are practical, hands-on, and heavily guarded experiences. You will sit at a dedicated exam machine, log in without any internet access (no Google, no Stack Overflow), and face a series of coding challenges.
Expect exercises that mirror the structure of your daily projects, starting very simply and increasing in difficulty:
Grasping types, scope, and the basic arithmetic that drives logic.
Counts and returns the number of characters in a string (excluding the null terminator). ft_rev_int_tab: Reverses an array of integers. c piscine exam 01
You start at Assignment 0. If you pass it, you move to Assignment 1. If you fail an assignment because of a typo, memory leak, or incorrect output, you must retry that level with a completely different problem. 2. Core Concepts Tested in Exam 01
words = count_words(str, c); result = malloc(sizeof(char *) * (words + 1)); if (!result) return (NULL); // ... fill the array ... result[words] = NULL; return (result);
Convert a string (in a given numeric base, e.g., binary, hex) into an integer. This requires handling +/- signs, whitespace, and invalid characters. It is the ultimate test of string traversal. At the 42 Piscine, exams are practical, hands-on,
Expect problems that ask you to compare numbers, find the maximum or minimum in a set, or determine if a number is prime. These tests evaluate your ability to translate logical requirements into efficient code using if-else statements and loops. The Importance of Norminette
I thoroughly understand how pointers point to memory addresses.
void reverse(char *s) char *i = s, *j = s + strlen(s) - 1; while (i < j) char t = *i; *i++ = *j; *j-- = t; Counts and returns the number of characters in
Many brilliant coders fail Exam 01 because of simple, avoidable mistakes. Moulinette does not care about good intentions; it only cares about binary perfection. 1. Missing the Forbidden Functions Rule
Among the many grueling hurdles you will face, stands as a notorious gatekeeper. It is the second major exam of the month-long coding bootcamp, designed to separate those who merely memorize from those who truly understand memory allocation, pointers, and string manipulation.
Functions like ft_putnbr or ft_atoi (converting strings to integers) often appear as "gatekeeper" questions later in the exam. 3. Common Pitfalls
Swapping values using pointers, modifying integers via pointer references, and handling pointers to pointers (double pointers).