作者ymzk ()
看板C_Sharp
标题[问题] 指令不通@@"
时间Sat Sep 14 19:55:38 2013
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApplication1
{
class Program
{
string a;
static void Main(string[] args)
{
a = Console.ReadLine();
}
}
}
以上是我的CODE 但为什麽不能通呢?
--
Windows 3.1 仓颉输入 _ By ymzk
┌─────────────────────────────────────┐
│┌──┐┌──┐ ┌────────┐┌───┐ ┌─┐┌──┐│
││仓颉││半形│请输入字根:│水土戈 ││ │ │,││键盘││
│└──┘└──┘ └────────┘└───┘ └─┘└──┘│
└─────────────────────────────────────┘
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 180.177.2.7
1F:→ killer1121:a的内容是什麽? 你只是定义没有给内容 09/14 20:01
2F:→ killer1121:想法错误..ORZ 09/14 20:11
3F:→ markov:楼上你是对的 另外值接 Console.ReadLine(); 应该会是pause 09/14 20:17
4F:推 Harper34:static string a; 09/14 20:18
5F:→ henry10423:一楼根本讲错,可以直接宣告啊,那是因为版主没加上sta 09/14 20:52
6F:→ henry10423:tic,最後还要记得暂停,Console.Readkey(true); 09/14 20:52
7F:→ s3748679:应该叫楼主吧.... 版主是外面那个 09/15 12:05
8F:→ MrJerome:错误讯息是什麽? 09/15 17:00
9F:推 optimist9266:去把new关键字看懂吧 你在静态方法呼叫动态栏位 09/15 23:36
10F:推 tomoyaken14:那里不通?哪里出错? 难道是没有输出吗? @@? 09/16 13:54
11F:推 johnny94:应该是 string 没加上 static 09/23 18:28