Trying to understand what's going on with the console output... scanf makes a mess apparently. https://devnet.jetbrains.com/message/5530456#5530456