RUVIDEO
Поделитесь видео 🙏

TCS Proctored assessment February 2021 | Java program

My channel : https://www.youtube.com/channel/UCKydQnv1LDPtJZdnMNQagTA
Previous Video : https://youtu.be/nlbAwjcm89U
Next Video :

TCS Proctored assessment February 2021 | Java program


TCS Proctored Assessment of February 2021
Create a class Voter with the below attributes:
voterid - int
voterName - String
voterAge - int
isVoteCasted - boolean
constituency - String
The above attributes should be private, write getters, setters and parameterized constructor as required.
Create class MyClass with main method .
Implement two static methods - findTotalVotesCastedByConstituency and searchVoterByAge in MyClass class.
findTotalVotesCastedByConstituency method: This method will take two input parameter - array of Voter objects and String parameter. The method will return the total numbers of votes casted from array of Voter objects for the given Constituency (String parameter passed). If no Vote has been casted for the given constituency in the array of Voter objects, then the method should return 0 .
searchVoterByAge method: This method will take an array of Voter objects as a parameter. The method will return Voter object array in an ascending order of their voterld, from the array of Voter objects where voterAge is less than 30. If no voter with age less than 30 is present in the array of Voter objects, then the method should return null.
Note : NO two voter object would have the same voterld. All the searches should be case insensitive.
The above mentioned static methods should be called from the main method.
For findTotalVotesCastedByConstituency method -The main method should print the total number of votes tasted as it is, if the returned value is greater than 0, or it should print "No votes casted"
For searchVoterByAge method - The main method should print the voterlD from the returned Voter object array if the returned value is not null. If the returned value is null then it should print "No such voters".
Before calling these static methods in main, USI Scanner object to read the values of four Voter objects referring attributes in the above mentioned attribute sequence. Next, read the value of String parameter for capturing the constituency .
Consider below sample input and output:
Input
1008
Aman
29
true
cons1
1003
Saman
43
true
cons1
1004
Kamal
28
false
cons2
1005
Ritu
48
true
cons1
cons1
Output:
3
1004
1008

Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «TCS Proctored assessment February 2021 | Java program», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.

Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.

Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!

Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.