Ada编程.Put_line和Put_line之间有什么区别

  • 本文关键字:line Put 区别 编程 Ada 之间 ada
  • 更新时间 :
  • 英文 :


我正在努力学习阿达。Put_line和Put_line之间有什么区别?我想我看到它们可以互换使用,但不能证实这一点。

begin
Put("Please type in your name:  ");
get_line(yourName, Length);
New_Line;
Put(yourName(1..Length));
Put(" landed on an alien planet and was attacked by 50 aliens. ");
Put(yourName(1..Length));
Put(" fought bravely and killed 12 attackers, ");
Put("after which the reamining aliens fled.  ");
Put(yourName(1..Length));
Put(" was able to crawl back to his ship" );
Put(" where his medical officer successfully treated his wounds.");
end Short_Story2;

Put_line输出其输入并终止行,Put不输出。因此Put_Line("This"); Put_Line("That");产生

This
That

Put("This"); Put("That");产生

ThisThat

最新更新