Intermediate Tutorial 7

The Partridge Family were neither partridges nor a family. Discuss.
Post Reply
jamesmfox
Posts: 15
Joined: September 1st, 2017, 10:46 pm
Location: Mississippi, USA

Intermediate Tutorial 7

Post by jamesmfox » September 13th, 2017, 4:56 am

I Just finished the homework for tutorial 7(streams, std::string). Chili asked to make snek game use a config file. I was hoping someone wouldn't mind looking over my code and giving me some pointers :D

https://github.com/JamesMFox/SnekGame/tree/I7-hw

User avatar
chili
Site Admin
Posts: 3948
Joined: December 31st, 2011, 4:53 pm
Location: Japan
Contact:

Re: Intermediate Tutorial 7

Post by chili » September 14th, 2017, 4:20 am

Seems alright. I personally prefer using >> directly for parsing. Less stuff to mess around with (substr / stoi). If you wanted to take things further, some error detection (missing fields) would be nice.

Overall, it works and isn't too hard to follow, good works.
Chili

Post Reply