Welcome   HUNAN NORMAL UNIVERSITY ACM/ICPC Judge Online
Home
FAQs
Problem Set
Practices
Online Contests
Major Exercises
OI Special
Judgement
Submit
Online Status
User Ranklist
Users
Register new
Login
Web Links
Hunan Normal University
College of Information Science and Engineering
对象传入函数 
Time Limit: 1000ms, Special Time Limit:2500ms, Memory Limit:32768KB
Total submit users: 10, Accepted users: 9
Problem 11608 : No special judgement
Problem description
  函数也能返回但是这个过程并不是这么简单。请采用对象传入函数的方式来计算三角形的面积,此外对这个三角形类设置其构造函数和析构函数,且构造函数中应输出Constructing,析构函数中应输出Destructed.对于求面积的函数请采用普通函数。

Input
  每次输入三个浮点数a ,b,c ,分别表示三角形的三条边的长度,输入都能构成一个三角形。

Output
  对于每一行的输入,在下一行输出中间过程所输出的字符串面积,面积保留两位小数。

Sample Input
3 4 5
Sample Output
Constructing
Destructed
6.00
Destructed
Submit   Clarifications   Judge Status  Problems  Ranklist 

HUNAN NORMAL UNIVERSITY ACM/ICPC Judge Online, Version 2010.5.5.final.
Web visits:2240 today,16258967 total, since 2010-05-07