【Perl,PHP】LLバトルロワイヤル7【Ruby,Python】
■ このスレッドは過去ログ倉庫に格納されています
0380デフォルトの名無しさん
2009/09/19(土) 22:21:52foo = 1 if bar;
I'd also like to suggest my favorite looping construct from Pick Basic (yes Basic):
loop {
x = doSomething();
} while (!x) {
doSomethingElse();
}
putting the test in the middle of the loop allows you to dispense with any setup code for the loop
that has to be repeated within the loop -- it all goes before the test and will be executed again
for each iteration.
■ このスレッドは過去ログ倉庫に格納されています