Ada编程。 Put和Put_line有什么区别

时间:2018-08-06 15:45:25

标签: ada

我正在尝试学习Ada。 Put和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;

1 个答案:

答案 0 :(得分:3)

<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet" /> <div class="card-deck"> <div class="card" style="margin-top: 0px"> <div class="card-body"> <a> <img class="card-img" src="{{banner.FeatureImage0.Url}}" alt="Card image cap" style="width:200px; height: 132.531; float: right; margin-left:10px;"> </a> <h5 class="card-title">Get to Know...FirstName LastName</h5> <p class="card-text" style="margin-bottom: 20px;">In this interview we feature FirstName LastName, Community Relations and Social Responsibility Officer, Executive Vice President.</p> <a class="btn btn-primary" style="color:white !important;">Read More</a> </div> </div> <div class="card" style="margin-top: 0px"> <div class="card-body"> <a> <img class="card-img" src="{{banner.FeatureImage0.Url}}" alt="Card image cap" style="width:200px; height: 132.531; float: right; margin-left:10px;"> </a> <h5 class="card-title">Questions are more important than answers - August ethics message</h5> <p class="card-text" style="margin-bottom: 20px;">The August ethics message comes from FirstName LastName, Wisconsin Region CEO.</p> <a class="btn btn-primary" style="color:white !important;">Read More</a> </div> </div> </div>输出其输入并终止该行,Put_line不输出。因此,Put产生了

Put_Line("This"); Put_Line("That");

This That 产生

Put("This"); Put("That");