SPOJ 7236 "The next odd number"

問題:https://www.spoj.pl/problems/NEXTODD/

100B以内の問題なのでテキトーにTclで.

while {![eof stdin]} {
        gets stdin n
        puts [expr $n+1+$n%2]
}