Register    Login    Forum    Search    FAQ

Board index » Everything




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Intermediate Tutorial 7
 Post Posted: September 13th, 2017, 4:56 am 
 

Joined: September 1st, 2017, 10:46 pm
Posts: 13
Location: Mississippi, USA
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


Top 
 Profile  
Reply with quote  
 Post Posted: September 14th, 2017, 4:20 am 
Site Admin
User avatar

Joined: December 31st, 2011, 4:53 pm
Posts: 3402
Location: Japan
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


Top 
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
 
Post new topic Reply to topic  [ 2 posts ] 

Board index » Everything


 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron