
ruby
iteye_2220
这个作者很懒,什么都没留下…
展开
-
使用ruby读取文件
[code="ruby"]=begin 使用ruby读取指定路径的文件=endfileName = ARGV[0] #获取从控制台输入的文件路径file = open(fileName) #打开文件while text = file.gets do #使用while每循环一次,输出一行字符串 print text #向控制台打印内容end #当text为nil时就结束循...原创 2011-05-23 01:01:33 · 285 阅读 · 0 评论 -
Hello World
[code="java"]public class HelloWorld { public static void main(String[] args) { System.out.println("Hello World"); }}[/code][code="jsp"][/code][code="c"]#include "stdio.h"void...原创 2011-07-29 00:41:54 · 107 阅读 · 0 评论