خرید بک لینک

Vote count: 0

I need to take input in the form of- Given 'n' number of boxes and each of these boxes may contain any number of distinct integers, So first user enters n,then for each value of i from 1 to n,I need to enter values till enter is pressed. I don't know how to do this, Eg-

5
1 2 3 4 5 6 7 8 9 
1 2
1 
4 5 6
3 4 5 6 7

I have tried this-

String str=scaer.next();
for(int i=0;i<n;i++)
{
    while(true)
    {
       if(str.isEmpty())
          break;
       int val=Integer.parseInt(str);
    }
}

Also tried str.equals("n") and str.equals(""), But nothing is working. Somebody please help me out.Thanks.

asked 44 secs ago

برچسب: how to read literature like a professor,how to read a ruler,how to read palms,how to read music,how to read,how to read guitar tabs,how to read the bible,how to read tire size,how to read sheet music,how to read blood pressure, نویسنده: استخدام کار تاريخ: يکشنبه 28 شهريور 1395 ساعت: 14:54

صفحه بندی