<commit_before>####Question
Are the following declarations legal, if not why?  
(a) `int ff(int a, int b = 0, int c = 0);`  
(b) `char *init(int ht = 24, int wd, char bckgrnd);`
####Answer
(a) Legal, this function can be called with one, two, or three arguments.  
(b) Not legal, all parameters following an parameter with a default argument must also have default arguments. This problem can easily be fixed by reordering the parameters:
```
`char *init(int wd, char bckgrnd, int ht = 24);`
```<commit_msg>Update Exercise_06_40.md<commit_after>####Question
Are the following declarations legal, if not why?  
(a) `int ff(int a, int b = 0, int c = 0);`  
(b) `char *init(int ht = 24, int wd, char bckgrnd);`
####Answer
(a) Legal, this function can be called with one, two, or three arguments.  

(b) Not legal, all parameters following an parameter with a default argument must also have default arguments. This problem can easily be fixed by reordering the parameters:
```cpp
char *init(int wd, char bckgrnd, int ht = 24);
`
{'fraction_non_alphanumeric': 0.11609756097560976, 'fraction_numerical': 0.015609756097560976, 'mean_word_length': 4.576086956521739, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1777713', 'n_tokens_mistral': 346, 'n_tokens_neox': 319, 'n_words': 156}