Take FREE!! Online Mettl Mock Test to Crack TechM and Other Companies Written Exams.
Get Off-Campus Placement Jobs Info !!!
TCS NQT Technical and Managerial Round Interview Questions
Interview Questions and Answers :: Broadcom Ltd

32. Write the program to find the sum of two numbers & positions in an array to a numbers.


int a[]= {2,3,4,7,9,3,8,9,6,8,7,9};
int i=0;
int j=0;
int n=12;
int sum=12;
for (i=0;i {
for(j=++i;j {
if ((a[i]+a[j]) == sum)
printf("\n %d + %d positions of sum %d", a[i], a[j], sum);

Post Your Answer Here:      Public      Private

Rate This: +0 -0

Post Your Reply Here:     

Report Error

Report Error

Please Login First Click Here