基本上我正在用 C# 制作一个刽子手游戏,但问题是每当我试图用它来表达我的string意思char[]时word.ToCharArray();它都不起作用。有人可以弄清楚这段代码有什么问题吗?List<string> words = new List<string>();List<string> guessedLetters = new List<string>();string word = "sword";// Turning word into char arraychar[] letters = word.ToCharArray(); CS0236 字段初始值设定项不能引用非静态字段、方法或属性 'Form1.word' final C:\Users*\Desktop\final\final\Form1.cs 20 Active
3 回答
- 3 回答
- 0 关注
- 162 浏览
添加回答
举报
0/150
提交
取消