Content warning: This post contains sexist material that might make your brain melt.
Update (June 2020): Course provider has promised to change the wording of their exercises! That is great!
I could not believe my eyes when I saw this programming exercise on a C++ course that is widely offered in Finnish Universities.
How many mistakes can you spot here?
“Write a program that asks the users gender and age. Finally the program prints a sentence based on the following rule:
- Male 0-55 years: “You are a man in his prime!”
- Male 56-100 years: “You are a wise man!”
- Female 0-55 years: “You are like a blooming flower!”
- Female 56-100 years: “You look young for your age!”
- Else “Error encountered!” Age is handled as an integer variable and gender as string variable (m/f). Letter case is ignored.”
And if someone does believe this is true, here's a screencap of it:
This might be some wicked way of pointing out sexism in IT industry. In my opinion, simply, not cool!