SHARE
TWEET

Untitled

a guest Oct 20th, 2019 79 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. public class U0901Main {
  3.  
  4.     public static void main(String[] args) {
  5.         Integer intArr[]= {10,20,15};
  6.         Float floatArr[] = new Float[3];
  7.         for (int i =0; i<floatArr.length; i++ ) {
  8.             floatArr[i] = (float) (Math.random() * 50);
  9.         }
  10.        
  11.         U0901WorkArray<Integer> insWorkArrayInt = new U0901WorkArray(intArr);
  12.         U0901WorkArray<Integer> insWorkArrayFloat = new U0901WorkArray(floatArr);
  13.         insWorkArrayInt.sum();
  14.         insWorkArrayFloat.sum();
  15.         System.out.println(insWorkArrayInt.sum());
  16.         System.out.println(insWorkArrayFloat.sum());
  17.        
  18.        
  19.         String line = "Конфеты 'Маска';45;120";
  20.         String[] item_fld = line.split(";");
  21.        
  22.         for (String a: item_fld)
  23.             System.out.println(a);
  24.        
  25.         FoodItem testline = new FoodItem(item_fld[0], Float.parseFloat(item_fld[1]), Short.parseShort(item_fld[2]));
  26.         testline.printAll();
  27.        
  28.        
  29.        
  30.     }
  31.    
  32.  
  33. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top