txt.txt 檔案內容
one= 11
two=22
three =33
four=44
five=55
using System;
using System.Collections.Generic;
class Program {
static void Main(string[] args) {
Dictionary varWith = new Dictionary( );
varWith.Add("one", "");
varWith.Add("two", "");
varWith.Add("three", "");
varWith.Add("four", "");
varWith.Add("five", "");
string[] lines = System.IO.File.ReadAllLines(@"txt.txt");
foreach (string line in lines) {
if(line.IndexOf("=")<1 console.writeline="" continue="" foreach="" if="" in="" kvp.key="" kvp.value="" kvp="" line.indexof="" line.substring="" pre="" rim="" t="" var="" varwith.containskey="" varwith="">1>
沒有留言:
張貼留言