Bài tập 3: Với từng đoạn chương trình, hãy cho biết lệnh Writeln in ra màn hình giá trị của J, k là bao nhiêu? Đoạn chương trình 1: J:=0; k:=0; For i:=1 to 5 do J:=J+1; k:= k+J; writeln(J,’ ‘, k); Đoạn chương trình 2: J:=1; k:=0; For i:=1 to 5 do Begin J:=J+1;k:= k+J; end; writeln(J,’ ‘, k);
2 câu trả lời
Câu hỏi trong lớp
Xem thêm