作者chuankun (欢迎光临)
看板perl
标题[问题] 关於一段程式输出的问题
时间Thu Mar 18 12:48:59 2004
@str = <STDIN>;
@str = sort @str;
print "@str";
想请问一下为什麽 print那一列有加 "" 时 @str印出来的时候不能对齐?
例如
<STDIN>输入
a
c
b
执行结果却是
a
b #前面多一个空白
c #前面多一个空白
如果不加""结果就正常
a
b
c
--
九斗桑海田园
http://uuu.to/mulberry/
桑椹采果、咖啡、花草茶、桑椹简餐
欢迎您的光临!!
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.112.79.15