Java车号直方图

时间:2019-05-26 19:34:18

标签: java

这是我分配Java老师的第一个程序问题,需要任何人帮助识别问题,非常感谢

import java.util.*;

public class carSale {

    public static void main(String[] args) {          
        String [] months = january, february, march, april, may, june,        
        String [] = new String [6];  
        int[] monthlySale = new int[6];    
        int monthlySale[] = {191, 196,269, 308,236, 145};
        int[] column = new int[6]; 
        monthlySale [i] = 0.0;
        int sum = 0;  
        for(int i=0; i < monthlySale.length ; i++);
        sum = sum + monthlySale[i];       
        System.out.println("Sum value of 6 months are : " + sum);
        double average = sum / numbers.length;
        System.out.println("Average value of the array elements is : " + average);  
        // step 8:
        // draw horizontal bar graph (one line per roll value)            
        for (int column = 0; column <= monthlySale.length; column++); { 
            System.out.println((monthlySale(i)) / 11 + "\t" + (monthlySale(i)) );  
            System.out.println();
        }
    } 
}

0 个答案:

没有答案