Follow Our FB Page << >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

How to implement flags?

Answers were Sorted based on User's Feedback

How to implement flags?..

Answer / subeetha

C++ defines some format flags for standard input and
output, which can be manipulated with the flags(), setf(),
and unsetf() functions. For example,


Is This Answer Correct ?    1 Yes 0 No

How to implement flags?..

Answer / sachin

enum Flag {Yes, No};

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More C++ General Interview Questions

Explain "const" reference arguments in function?

0 Answers  

What is the benefit of c++?

0 Answers  

When do you call copy constructors?

0 Answers  

I was a c++ code and was asked to find out the bug in that. The bug was that he declared an object locally in a function and tried to return the pointer to that object. Since the object is local to the function, it no more exists after returning from the function. The pointer, therefore, is invalid outside.

0 Answers  

What is abstraction in c++?

0 Answers  

class HasStatic { static int I; }; Referring to the sample code above, what is the appropriate method of defining the member variable "I", and assigning it the value 10, outside of the class declaration? a) HasStatic I = 10; b) int static I = 10; c) static I(10); d) static I = 10; e) int HasStatic::I = 10;

1 Answers   Quark,

How come you find out if a linked-list is a cycle or not?

0 Answers  

Why is it called c++?

0 Answers  

Does a derived class inherit or doesn't inherit?

0 Answers  

List the advantages of inheritance.

0 Answers  

What is scope of a variable? (LOLZ)

2 Answers   CA, TCS,

how many rounds and wt type of questios ask in the written test for first round 2. tech. round 3. and futher rounds

0 Answers   Thought Works,