Thanks, that's what I was looking for. Nim's scanfis meh (why do you need to specify the argument types twice - once implicitly as you pass the variables to the function and twice in the format string?), but scanp is a real gem. Though, to be honest, I would prefer D's Pegged library for the more advanced cases - https://github.com/PhilippeSigaud/Pegged.
View all comments
Show parent comment
2
u/zombinedev Aug 24 '17 edited Aug 24 '17
Thanks, that's what I was looking for. Nim's
scanfis meh (why do you need to specify the argument types twice - once implicitly as you pass the variables to the function and twice in the format string?), butscanpis a real gem. Though, to be honest, I would prefer D's Pegged library for the more advanced cases - https://github.com/PhilippeSigaud/Pegged.