Code Snippets Interview Questions
Questions Answers Views Company eMail

Create a class called Accounts which has data members like ACCOUNT no, Customer name, Account type, Transaction type (d/w), amount, balance D->Deposit W->Withdrawal If transaction type is deposit call the credit(int amount) and update balance in this method. If transaction type is withdraw call debit(int amt) and update balance. Pass the other information like Account no,name,Account Type through constructor. Call the show data method to display the values.

Cognizant,

1 6263

int main() { int x=10; printf("x=%d, count of earlier print=%d", x,printf("x=%d, y=%d",x,--x)); getch(); } ================================================== returns error>> ld returned 1 exit status =================================================== Does it have something to do with printf() inside another printf().

1 4757

int main() { int x=10; printf("x=%d, count of earlier print=%d", x,printf("x=%d, y=%d",x,--x)); getch(); } ================================================== returns error>> ld returned 1 exit status =================================================== Does it have something to do with printf() inside another printf().

2 5042

There are 21 people in a room. They have to form groups of 3 people each. How many combinations are possible? Write a C program to print the same.

TCS,

1 4364

Write a C program to print ‘Campus Force training’ without using even a single semicolon in the program.

Wipro,

3 7791

Write a C++ program without using any loop (if, for, while etc) to print prime numbers from 1 to 100 and 100 to 1 (Do not use 200 print statements!!!)

iGate,

3491

is public static void main() work in java?is "String arg[]" needed as argument?

Tech Mahindra,

4 6952

‎#define good bad main() { int good=1; int bad=0; printf ("good is:%d",good); }

2 4655

what is software testing

TCS,

1 4158

Write a program to check whether the number is prime and also check if it there i n fibonacci series, then return true otherwise return false

Cognizant, lenovo,

1 5147

using friend function find the maximum number from given two numbers from two different classes.write all necessary functions and constructor for the classes.

TCS,

1 17783

write a function to give demostrate the functionality of 3d in 1d. function prototye: change(int value,int indexX,int indexY,int indexZ, int [] 1dArray); value=what is the date; indexX=x-asix indexY=y-axis indexZ=z-axis and 1dArray=in which and where the value is stored??

Nagarro,

4388

There is a lucky draw held every day. if there is a winning number eg 1876,then all possible numbers like 1867,1687,1768 etc are the numbers that match irrespective of the position of the digit. Thus all these numbers qualify fr the lucky draw prize Assume there is no zero digit in any numbers. write a program to show all the possible winning numbers if a "winning number"is passed as an arguments to the function.

Nagarro,

1 7480

how to concatenate the two strings

1 3584

iam getting keyword or delimiter error while executing ICETOOL,provide me solution.

1386


Un-Answered Questions { Code Snippets }

What is 301 redirects in php? When are we used 301 redirects in our projects?

2131


Write a code snippet to display an integer in a binary format?

637


Write a function that takes an array of integers and returns that array rotated by N positions. For example, if N=2, given the input array [1, 2, 3, 4, 5, 6] the function should return [5, 6, 1, 2, 3, 4]

1984


Design a timer circuit using VHDL which has the following: input : start_timer(ST) output: long_time(LT) short_time(ST) when the timer is triggered by the ST(either 0 or 1) signal the timer should generate two timing signals accordingly.While the long time is going ON the other should be OFF and vice versa.

2230


Write a program to reverse a number in python?

574






What is the code of Password Recovery or Forget your password? Plz tell in c # language.

3731


What are the basic rules while writing XML?

402


how to take time as input in the format (12:02:13) from user so that controls remains between these columns?

2039


What is XML Element?

488


what is main difference between array_push and array_pop?

3885


How do you verify if the two sentences/phrases input is an anagram using predefined functions in string.h and by using arrays?

2252


Write a python program to check if a number is a prime number?

601


ArrayList declaration in .net

2945


How can manage theme in php?

2171


I have multiple datasets and I have to search a particular string in all of them at a single time. Please suggest a full jcl or rexx tool for it.

834