레일에있는 루비는 ++ 값과 같은가? C에서++ 값 또는 값 ++ in rail (ruby)
는 X ++
그들은 (엄밀히 말하면) 같은 동작을하지 않습니다 .. 는 ++의 x는 레일
c++ code
int x = 0;
if(x++) cout << "value is not zero when compared"
else cout << "value still zero when compared"
//prints "value still zero when compared"
x = 0;
if(++x) cout << "value is not zero when compared"
else cout << "value is still zero when compared"
//prints "value is not zero when compared"
시뮬 뭔가가 있나요 빠른 거기 ++의 X이고 작업 (작지만 빠른),하지만 그게 내가 원하는 이유는 .. 내가 인쇄하고 같은 라인에 값을 추가하고 싶습니다 ..하지만 추가하기 전에 값을 인쇄하고 싶습니다.
루비 코드
#print out the count of products processed, the current id, and the current name
p "#{recCount++}:#{product.id} #{product.name}";
게시물 증가가 보이지 않습니다 ([link] (http://devblog.avdi.org/2011/02/26/ruby-or-why-post-increment-is-tricky/)). . – dasblinkenlight
팹 링크 :) .. 나를 슬프게하다 .. "언어 변호사"가된다 – baash05