How many lines of code you have written for a single program?

Answers were Sorted based on User's Feedback



How many lines of code you have written for a single program?..

Answer / ilakya.g

Atleast there should be 4 lines.it must consists of main
with the parenthesis and atleast a statement in it.

Is This Answer Correct ?    6 Yes 5 No

How many lines of code you have written for a single program?..

Answer / ashish. j

It depends on what kind of project you are working on.
Specially in a OOD, you have classes and objects. Ask the
interviewer if he wanted the number of lines in the whole
project or just one of the files. Every file can vary from
just 4 lines as stated above by Ilakya.g or it can have
more than 50 lines as needed. I haven't worked in very big
projects yet. But, the small projects I have worked on had
at least 30 lines per class and about 5 classes. That
multiplies to be about 150 lines for the project. Again,
keep in mind, it was a very tiny project. The number of
lines can vastly change if the project is bigger.

Is This Answer Correct ?    3 Yes 2 No

How many lines of code you have written for a single program?..

Answer / vijay kumar

from c program structure there should be atleast three lines
example like that

main()
{
}

there are no requard of header files

Is This Answer Correct ?    2 Yes 1 No

How many lines of code you have written for a single program?..

Answer / george

If you want to make a simple Hello World program in a
Comand propt(Console) window. Here is its shortest's code:

#include "stdafx.h"
#include <iostream>
using namespace std;

int main()
{
cout << "Hello world" << endl;

cin.get();
return 0;
}
Check out my Youtube channel for 2 tutorials and see how
long can very very simple apps be!
http://www.youtube.com/user/GGames2009

Is This Answer Correct ?    1 Yes 1 No

Post New Answer

More C++ General Interview Questions

Will a recursive function without an end condition every quit, in practice a) Compiler-Specific (Some can convert to an infinite loop) b) No c) Yes

0 Answers  


What is an adjust field format flag?

0 Answers  


What is c++ namespace?

0 Answers  


What is the default width for ouputting a long integer using the insertion operator?

0 Answers  


What does the following code do: int c=0; cout< a) Undefined *Updated* b) 01 c) 00

0 Answers  






How to declare a function pointer?

0 Answers  


What are the advantages of prototyping?

0 Answers  


C is to C++ as 1 is to a) What the heck b) 2 c) 10

0 Answers  


Can we make copy constructor private in c++?

0 Answers  


Difference between Constructors and static constructors?

3 Answers   IBM, TCS,


What is a namespace in c++?

0 Answers  


What is the topic of the C++ FAQ list?

1 Answers  


Categories