42 Exam Rank 03 Portable Jun 2026
Good luck. And remember: "There is no failure, only feedback."
| Task | Done? | |------|-------| | Can you write ft_printf handling %s , %d , %x , %% from memory? | ☐ | | Does your ft_printf return the correct byte count? | ☐ | | Have you memorized get_next_line with static stash[4096] ? | ☐ | | Do you handle BUFFER_SIZE=1 correctly (reading char by char)? | ☐ | | Does your GNL free the stash after EOF and return NULL? | ☐ | | Have you tested with two files interleaved? | ☐ | | Is your code Norminette-compliant (25 lines max per function, no tabs)? | ☐ | | Have you practiced the exam in a timed, no-internet mock? | ☐ | 42 Exam Rank 03
Historically, the revolves around two functions: get_next_line and a secondary function called ft_printf or sometimes ft_itoa (depending on your campus iteration). However, the most common and feared version is Get Next Line (GNL) combined with a simple printf clone. Good luck
| Exercise | Difficulty | Data Structure | Recursion Required? | |----------|------------|----------------|----------------------| | ft_list_size | Easy | Singly linked list | No (iterative) | | ft_list_push_back | Easy | Singly linked list | No | | ft_list_last | Easy | Singly linked list | No | | ft_list_foreach | Easy | Singly linked list | No | | ft_list_remove_if | Medium | Singly linked list | No | | ft_list_reverse | Medium | Singly linked list | No | | ft_list_sort | Medium-Hard | Singly linked list | Optional | | ft_list_merge | Medium | Singly linked list | No | | ft_itoa_base | Medium | String (no struct) | No (but tricky) | | ft_atoi_base | Medium | String (no struct) | No | | ft_split_whitespaces | Easy | String → array | No | | ft_range | Easy | Array | No | | ft_ultimate_range | Easy | Array | No | | ft_strjoin | Easy | String | No | | ft_btree_create_node | Easy | Binary tree | No | | ft_btree_apply_prefix | Medium | Binary tree | Yes | | ft_btree_apply_infix | Medium | Binary tree | Yes | | ft_btree_apply_suffix | Medium | Binary tree | Yes | | ft_btree_insert_data | Hard | Binary tree | Yes | | ft_btree_search_item | Medium | Binary tree | Yes | | ft_btree_level_count | Medium | Binary tree | Yes | | ft_btree_apply_by_level | Hard | Binary tree | Yes (with queue) | | ☐ | | Does your ft_printf return the correct byte count
"The secret is to memorize your get_next_line code 100%. Write it on paper ten times before the exam day. Muscle memory will save you when your brain freezes." — 42 Berlin student.
struct s_list *next; void *data; t_list;
Rank 02 focuses on simple string/array manipulation with moderate pointer use. Rank 03 introduces recursion as the primary problem-solving tool and often requires you to build and traverse data structures (linked lists, binary trees).
