課程
/后端開發
/C#
/C#開發輕松入門
4-2怎么做
2016-10-11
源自:C#開發輕松入門 4-2
正在回答
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
? ? class Program
? ? {
? ? ? ? static void Main(string[] args)
? ? ? ? {
? ? ? ? ? ? int x;//循環計數變量
? ? ? ? ? ? x=5;//行① 請填寫計數變量的初始化語句
? ? ? ? ? ??
? ? ? ? ? ? while ( x>0 ? )//行② 請填寫循環條件
? ? ? ? ? ? {
? ? ? ? ? ? ? ? Console.Write("加油!");
? ? ? ? ? ? ? ? x--;//行③ 請填寫計數變量的自加語句
? ? ? ? ? ? ? ??
? ? ? ? ? ? }
? ? ? ? }
? ? }
}
? ? ? ? ? ? x = 1;//行① 請填寫計數變量的初始化語句
? ? ? ? ? ? while (x<=5)//行② 請填寫循環條件
? ? ? ? ? ? ? ? x++;//行③ 請填寫計數變量的自加語句 ? ? ? ?
舉報
本門課程是C#語言的入門教程,將帶你輕松入門.NET開發
2 回答4-10編程題怎么做呀?
1 回答2—19課任務怎么做,怎么添加?
3 回答4-2
1 回答console.writeline(2*PI*4);
1 回答4-2 怎么添加其他字符串到輸出
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號-11 京公網安備11010802030151號
購課補貼聯系客服咨詢優惠詳情
慕課網APP您的移動學習伙伴
掃描二維碼關注慕課網微信公眾號
2016-10-12
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
? ? class Program
? ? {
? ? ? ? static void Main(string[] args)
? ? ? ? {
? ? ? ? ? ? int x;//循環計數變量
? ? ? ? ? ? x=5;//行① 請填寫計數變量的初始化語句
? ? ? ? ? ??
? ? ? ? ? ??
? ? ? ? ? ? while ( x>0 ? )//行② 請填寫循環條件
? ? ? ? ? ? {
? ? ? ? ? ? ? ? Console.Write("加油!");
? ? ? ? ? ? ? ? x--;//行③ 請填寫計數變量的自加語句
? ? ? ? ? ? ? ??
? ? ? ? ? ? }
? ? ? ? }
? ? }
}
2016-10-12
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
? ? class Program
? ? {
? ? ? ? static void Main(string[] args)
? ? ? ? {
? ? ? ? ? ? int x;//循環計數變量
? ? ? ? ? ? x = 1;//行① 請填寫計數變量的初始化語句
? ? ? ? ? ? while (x<=5)//行② 請填寫循環條件
? ? ? ? ? ? {
? ? ? ? ? ? ? ? Console.Write("加油!");
? ? ? ? ? ? ? ? x++;//行③ 請填寫計數變量的自加語句 ? ? ? ?
? ? ? ? ? ? }
? ? ? ? }
? ? }
}