3. Team Division | InfyTQ Final Round Coding Questions | Java & Python | Phodo Coding Round



#infytq #finalround #infosys

This video brings you the coding questions asked in InfyTQ final rounds.
We will introduce questions from basic to advance level.
We hope you’ll enjoy the series.

Java Code: https://github.com/aakashverma1124/InfyTQ-Coding-Questions-Final-Round/blob/master/Java/P3_TeamDivision.java
Python Code: https://github.com/aakashverma1124/InfyTQ-Coding-Questions-Final-Round/blob/master/Python/P3_TeamDivision.py
——————————————————-
Instagram: http://instagram.com/aakashverma1102
LinkedIn: https://www.linkedin.com/in/aakashverma1124/

Additional Video Covers:

InfyTQ Final Round
InfyTQ Java Questions
InfyTQ Coding Questions
InfyTQ Final Round Coding Questions
InfyTQ Python Questions
InfyTQ Java Coding Questions
InfyTQ Python Coding Questions

20 thoughts on “3. Team Division | InfyTQ Final Round Coding Questions | Java & Python | Phodo Coding Round

  1. Is video mein shuruaat ke 1 min mein music galti se on reh gaya hai.
    Editing karte waqt pta hi nahi chala k music on hai or upload kardi.
    Maafi 🙏
    Tabiyat khraab thi to deemaag kaam ni kar raha tha 😑

  2. Size of the array is n, and while using the solve method recursively we are adding arr[n], how is dis working, i mean valid index for an array of size n should be from 0 to n – 1. ?????

  3. Sir, please tell me that are we allowed to use inbuilt libraries like re and itertools in final round of infytq?
    Please allso tell us does building main function in python in competitive round is necessary or we can go without it?

  4. Sir, can u please tell the number of static, instance and local variables in the following code:

    class classOne:

    __var_one = 1001

    def __init__(self,var_two):

    self.__var_two = var_two

    self.__var_five = 5

    def method_one(self):

    var_four = 50

    self.__var_five = ClassOne.__var_one + self.__var_two + var_four

  5. Can't we do this by greedy approach? By sorting the array first and taking two aux arrays in which we tends to keep the sum difference minimum by traversing from the back of sorted array and also maintaing a count so that none of the array contains more than one element in respect of the other one.

  6. I used bitmasking…this is my code
    lst=list(map(int,input().split(',')))
    n=len(lst)
    val=2**n
    ans=1e9
    s1=0
    s2=0
    for i in range(val):
    zero=0
    one=0
    su1=0
    su2=0
    for j in range(n):
    if ((1<<j)&i)>0:
    one+=1
    su1+=lst[j]
    else:
    su2+=lst[j]
    zero+=1
    if abs(one-zero)<=1:
    if ans>abs(su1-su2):
    ans=abs(su1-su2)
    s1=su1
    s2=su2
    print(s1,s2)

Leave a Reply

Your email address will not be published. Required fields are marked *