Hello,
If I want to check my algorithm if it works good in every cases
so can i check very outer cases and then I can conclude that my algorithm works well in all cases?

1. values outside given bounds, like what the sqrt() runtime function does:
It is able able to return NaN or +INFINITY and sets errno=EDOM (unix only).

2. validate output for known value sets, with extremely large/small or postivie/negative values

3. Deliberately try to break the code - if it expects numeric data feed it text instead of numbers, for example. In all cases it should simply return an error, not crash.
It should NOT exit. Whether or not an exit is called depends on the rules of operation of the program, not on an individual function.

Consider reading 'The Pragmatic Programmer' - it explains how functions (algorithms) are supposed to behave when users are trying to feed them data.

First thank you for the good answer :p
secondly i want to ask you something:
if I have an algorithm that solves questions with order of arithmetic operations than my input values can be very long, so I am trying to input something extreme small like:(0+0) or something extreme long and big like:
(2+4*(7/9-(6+7)+(789-9900)+6788-9/(45-998))) and then if my algorithm solves this inputs then I can conclude that my algorithm solves all the inputs i will give him?(and after i will try to input him string and it will not crash)

(2+4*(7/9-(6+7)+(789-9900)+6788-9/(45-998))) and then if my algorithm solves this inputs then I can conclude that my algorithm solves all the inputs i will give him?

Hi,

Just becoz u give ur algorithm this case doesn't mean it works 4 all cases. U might give him many cases and they all appear 2 work. This doesn't not prove him to work it evry case.

For example, there might B 1 case that u forget.

To prove something is not to test alot. But to convince the reader through logic that your answer is the only obtanable solution.

There is something called formal programming or something similar that enables you to state post and preconditions allowing you to "prove" that your code does what you say it does (might have been called formal method)...
This is probably what I was thinking about... http://en.wikipedia.org/wiki/Formal_method

So for this program im trying to print out the max height the projectile reaches and when i run the str on the object it dosent change the value to ...

Is C similar to C# (C-sharp); or are they completely different ? I was wondering if I should begin learning C# and the transition to C will be a tad ...

Write a program that displays all numbers divisible by 3 and 4 within a range entered by user. Display five numbers per line. Numbers are separated by exactly two spaces. ...