C++ Program Required with arrays [closed] - c++

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 11 years ago.
I want to write a program which will show the numeric value of odd, even & zero values in array. The problem is that when I input values in array, C++ compiler doesn’t view the result and finishes the output window . Is there any solution for this?

Assuming you mean why the console window closes, you can add cin.get() to the end.

Related

Execution Control In C [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 9 years ago.
I was solving a problem where i was asked to output the list of numbers satisfying certain conditions. The score awarded depended upon the size of the output ( as it is a partial marking question). How do i restrict my code to keep outputting the numbers till it does hits the time limit.
It seems like the obvious structure would be something like this:
while (current_time < end_time) {
current_number = *next_number++;
if (meets_conditions(current_number))
output(current_number);
}

How can I stop a loop when an error occurs in imacros? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I want to fill my from four times.i take one csv file with four columns data.after inserting the first data one error is occurred.but imacros loop is not stoped.it leaves the first error and continuing other process.i want to stop the loop when error occured.
remove set !errorignore from your script

EMACS regex,How to work only in the designated few lines [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
For example, I just want it to work in the 1-10 lines, how to do it. A rookie, thanks for help.
You can use narrow-mode, and it will display only the first 10 lines, hiding the rest.

C++ "infinite" length text [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 11 years ago.
my task is to make a program that can store arbitrary long text in c++.
I have no idea how to solve this.
Also, you cannot use STL.
someone please help
allocate initial buffer (malloc())
store data into buffer until full (strcpy(), strcat(), memcpy()...)
reallocate to a bigger buffer (realloc())
goto 2

validating the value in a integer...? [closed]

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 12 years ago.
how do v find a value in an integer is garbage or not???
Initialize it at point of declaration, and it can never be garbage.
Pass it to strfry and compare the returned value with the original.
I guess that you mean if a string contains a valid integer. Check out scanf or the stream equivalent of c++, or Boost lexical cast