TCS Exam 24th August 2022 2pm Slot Answers Live
Aptitude :-
1) 10
2) 0.4
3) 196
4) 0.18
5) 60
6) 34
7) 195
8) 716
9) 6.44
10) Rs. 28200
11) 10ltr
12) 15.55
13) 42
14) 6
15) 1640km
16) Rs 945
17) 264
18) 40000 or 50000
19) 6.667
20) 28
Aptitude Completed
--------------------------------------------------------------------
Verbal :-
1) Sustained stress because of the mother-in-law
2) Then the cricket field was
3) that i am always
4) Engaged,crown,completely,pioneer
5) 1-(B),2(D),3(c),4(A)
6) Mamta..
7) Laboured under, worried the teaspoons..
8) Majar Bombshell
OR
8) Major blow, weighing on demand,grapple with, spur capital flows
9) 2143
10) ABCED
11) CBDAE
12) RS
13) Something that changes over,in what is produced
14) has been made in reducing, remains a leading killer
15) Indigenous
16) amateur
17) C
18)PR
19) vile decided to postpone his trip
20) Vile had not been able to stick to original plans
21) RST
22) Ancient mathematician euclide geometry theories.
23) By visualizing space in geometrical dilite
24) the hypothesis..
25) it has been man's abiding interest..
Verbal Completed
--------------------------------------------------------------------
Reasoning :-
1) ZADE
2) B,C & E
5) Data
6) All statements
7) Father's father
8) k%
9) Lalit
10) Her (A)
11) The Case
12) Only
13) Both
18) IFM
19) M
20) k
Compled
--------------------------------------------------------------------
Advanced Quantitative :-
1) 0.11
2)x-y=1
3) Xsquare -2x+16=0
4) P&Q
5)0.66
6.15
7) 14
8) system engineer
9) 1246
10) 236
--------------------------------------------------------------------
Advanced Reasoning :-
1- ZADE
2- b,c and e
5- data in statement 1 is sufficient
6- all statements...
7- Father's Father
8- K%L$M
9- Lalit
10- other applications not to be accepted
11- Director
12- only assumption 1 is implicit
13- Both...
14- A and B
15- fig.473
18- IFM
19- M
20 -K
--------------------------------------------------------------------
Coding :-
1Ques
Answer:- C lang code
#include <stdio.h>
int main() {
int n, i, flag = 0;
printf("Enter a positive integer: ");
scanf("%d", &n);
if (n == 0 || n == 1)
flag = 1;
for (i = 2; i <= n / 2; ++i) {
if (n % i == 0) {
flag = 1;
break;
}
if (flag == 0)
printf("%d .", n);
else
printf("%d ", n);
return 0;
}
int main() {
int n, i, flag = 0;
printf("Enter a positive integer: ");
scanf("%d", &n);
if (n == 0 || n == 1)
flag = 1;
for (i = 2; i <= n / 2; ++i) {
if (n % i == 0) {
flag = 1;
break;
}
if (flag == 0)
printf("%d .", n);
else
printf("%d ", n);
return 0;
}
Two Parallel Roads Python Code :-
C language code :-
#include<stdio.h>
int main()
{
int n,m;
scanf("%d%d",&n,&m);
int a[n],b[m];
int temp[m+n];
for(int i=0;i<n;i++)
{
scanf("%d",&a[i]);
}
for(int i=0;i<m;i++)
{
scanf("%d",&b[i]);
}
int x=0;
for(int i=0;i<n;i++)
{
temp[x++]=a[i];
}
for(int i=0;i<m;i++)
{
temp[x++]=b[i];
}
for(int i=0;i<x;i++)
{
for(int j=i+1;j<x;j++)
{
if(temp[i]>temp[j])
{
int t=temp[i];
temp[i]=temp[j];
temp[j]=t;
}
}
}
int count=0;
for(int i=0;i<x;i++)
{
if(temp[i]==temp[i+1])
{
for(int j=i+1;j<x-1;j++)
{
temp[j]=temp[j+1];
count=1;
}
x--;
}
}
if(count==1)
{
x++;
}
if(x%2==0)
{
int mid=x/2;
int mid1=x/2-1;
int up=temp[mid]+temp[mid1];
float result=up/2.0;
printf("%.2f",result);
}
else
{
printf("%d",temp[x/2]);
}
return 0;
}
int main()
{
int n,m;
scanf("%d%d",&n,&m);
int a[n],b[m];
int temp[m+n];
for(int i=0;i<n;i++)
{
scanf("%d",&a[i]);
}
for(int i=0;i<m;i++)
{
scanf("%d",&b[i]);
}
int x=0;
for(int i=0;i<n;i++)
{
temp[x++]=a[i];
}
for(int i=0;i<m;i++)
{
temp[x++]=b[i];
}
for(int i=0;i<x;i++)
{
for(int j=i+1;j<x;j++)
{
if(temp[i]>temp[j])
{
int t=temp[i];
temp[i]=temp[j];
temp[j]=t;
}
}
}
int count=0;
for(int i=0;i<x;i++)
{
if(temp[i]==temp[i+1])
{
for(int j=i+1;j<x-1;j++)
{
temp[j]=temp[j+1];
count=1;
}
x--;
}
}
if(count==1)
{
x++;
}
if(x%2==0)
{
int mid=x/2;
int mid1=x/2-1;
int up=temp[mid]+temp[mid1];
float result=up/2.0;
printf("%.2f",result);
}
else
{
printf("%d",temp[x/2]);
}
return 0;
}
Two parallel working code:-
Storeroom code in c++ :-
#include<bits/stdc++.h>
using namespace std;
int main() {
int n1,n2,i,j,c;
cin>>n1>>n2;
int a[n1],b[n2];
set<int> s;
for(i=0;i<n1;i++)
{
cin>>a[i];
s.insert(a[i]);
}
for(i=0;i<n2;i++)
{
cin>>b[i];
s.insert(b[i]);
}
vector<int> v(s.begin(),s.end());
c=s.size();
if(c%2==1)
{
c=c/2;
cout<<v[c];
}
else
{
n1=c/2;
n2=n1-1;
float q=(v[n1]+v[n2])/2.0;
cout<<q;
}
return 0;
}
Answers Coming Soon....
0 Comments