Share Pastebin
Guest
Public paste!

Tetse

By: a guest | Mar 21st, 2010 | Syntax: C# | Size: 0.54 KB | Hits: 85 | Expires: Never
Copy text to clipboard
  1. public class Nota {
  2.         private float b1;
  3.         private float b2;
  4.         private float b3;
  5.         private float b4;
  6.        
  7.         public float getB1() {
  8.                 return b1;
  9.         }
  10.         public void setB1(float b1) {
  11.                 this.b1 = b1;
  12.         }
  13.         public float getB2() {
  14.                 return b2;
  15.         }
  16.         public void setB2(float b2) {
  17.                 this.b2 = b2;
  18.         }
  19.         public float getB3() {
  20.                 return b3;
  21.         }
  22.         public void setB3(float b3) {
  23.                 this.b3 = b3;
  24.         }
  25.         public float getB4() {
  26.                 return b4;
  27.         }
  28.         public void setB4(float b4) {
  29.                 this.b4 = b4;
  30.         }
  31.        
  32.         public float calcularMedia(){
  33.                 return (b1+b2+b3+b4)/4;
  34.         }
  35. }