vkekk
Full Member level 3
67 seats in train
Dear all
Pls help me how to proceed the below problems in C language . if anybody tell algorithm/flowchart , its great help for me...
1. Write a program for the problem: the array of integers indicating the marks of the students is given, You have to calculate the percentile of the students according to this rule: the percentile of a student is the %of no of student having marks less than him. For e.g.: suppose
Student Marks
A 12
B 60
C 80
D 71
E 30
F 45
Percentile of C = 5/5 *100 = 100 (out of 5 students 5 are having marks less than him)
Percentile of B = 3/5*100 = 60% (out of 5, 3 have marks is less than him)
Percentile of A = 0/5*100 = 0%.
2. there are 67 seats in train . there are only 5 seats in a row and in last
row there are only 2 seats.
One person can reseve only 5 seat at a time.
If person reserving seat , the care is atken that he may get all in row. if
seats are not available in row then the arrangement is so that person group
get nearby seats.
the following class is given
public class seat
{
char name;
int seat;
boolean isSeatempty
}
1.Draw require class digram and object diagram.
2.Write function seatallot(int noofperson)
to allocate seat with seat nuber printed for the each name.
Dear all
Pls help me how to proceed the below problems in C language . if anybody tell algorithm/flowchart , its great help for me...
1. Write a program for the problem: the array of integers indicating the marks of the students is given, You have to calculate the percentile of the students according to this rule: the percentile of a student is the %of no of student having marks less than him. For e.g.: suppose
Student Marks
A 12
B 60
C 80
D 71
E 30
F 45
Percentile of C = 5/5 *100 = 100 (out of 5 students 5 are having marks less than him)
Percentile of B = 3/5*100 = 60% (out of 5, 3 have marks is less than him)
Percentile of A = 0/5*100 = 0%.
2. there are 67 seats in train . there are only 5 seats in a row and in last
row there are only 2 seats.
One person can reseve only 5 seat at a time.
If person reserving seat , the care is atken that he may get all in row. if
seats are not available in row then the arrangement is so that person group
get nearby seats.
the following class is given
public class seat
{
char name;
int seat;
boolean isSeatempty
}
1.Draw require class digram and object diagram.
2.Write function seatallot(int noofperson)
to allocate seat with seat nuber printed for the each name.