Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted as Java by test ( 17 years ago )
package hausaufgabe4.polynom;

public class Polynom {
 
 
 private int n;
 private int o;
 private int q;
 private int r;
 private double p[];
 private int s;


 public Polynom(int n, int o, int q, int s) {
  this.n = n;
  this.o = o;
  this.q = q;
  this.s = s;
  double[] p = { n, o, q, s};
  }
 

 /**
  * @author Tim Häuser Fh-Account:thsr58
  * 
  */
 public static void main(String[] args) {
  
  
  
  // Polynom 5xˆ4 -2xˆ3 + xˆ2 - xˆ1 + 2
  // an der Stelle x = 2 berechnen:
  Polynom polynom1 = new Polynom(5, -2, 1 -1, 2);
  System.out.println( polynom1.value(2) );
  // Polynom 5xˆ4 -2xˆ3 + xˆ2 - xˆ1 + 2
  // an der Stelle x = 3 berechnen:
  System.out.println( polynom1.value(3) );
  // Polynom xˆ3 - xˆ1 + 3
  // an der Stelle x = 5 berechnen:
  Polynom polynom2 = new Polynom(1, 0, -1, 3);
  System.out.println( polynom2.value(5) );

  
 }

 private char[] value(int i) {
  // TODO Auto-generated method stub
  return null;
 }
 
}

 

Revise this Paste

Your Name: Code Language: