fork download
  1. class BasicPlan{
  2. private String name; //プラン名
  3. private int basicCharge; //基本料金
  4. private int include; //無料通話分(この料金分までの通話に対する料金は基本料金に含まれる)
  5. private int callingRate; //1分あたりの通話料金
  6. private int packetRate; //100パケット当たりのパケット料金
  7.  
  8. BasicPlan(String name,int basicCharge,int include,int callingRate,int packetRate){
  9. this.name = name;
  10. this.basicCharge = basicCharge;
  11. this.include = include;
  12. this.callingRate = callingRate;
  13. this.packetRate = packetRate;
  14. }
  15.  
  16. String getName(){
  17. return name;
  18. }
  19.  
  20. int getBasicCharge(){
  21. return basicCharge;
  22. }
  23.  
  24. int getInclude(){
  25. return include;
  26. }
  27.  
  28. int getCallingRate(){
  29. return callingRate;
  30. }
  31.  
  32. int getPacketRate(){
  33. return packetRate;
  34. }
  35.  
  36. int calcCharge(int minutes,int packet){
  37. /*引数で受け取った通話時間(分)とパケット数に応じた料金を計算し返却する
  38. 料金=基本料金+無料通話分を差し引いた通話料金+パケット料金*/
  39. }
  40. }
  41.  
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Main.java:39: missing return statement
	}
	^
1 error
stdout
Standard output is empty