日期:2014-05-18 浏览次数:20838 次
string s = File.ReadAllText(@"c:\test.txt"); string[] values = s.Split(new char[] { ' ' }, StringSplitOptions.RemoveEmptyEntries); float[] rs = new float[values.Length]; for (int i = 0; i < rs.Length; i++) rs[i] = float.Parse(values[i]);
------解决方案--------------------