diff options
author | maheshgudi | 2016-08-03 15:16:08 +0530 |
---|---|---|
committer | maheshgudi | 2016-08-03 15:16:08 +0530 |
commit | 40fbb5d8f1d4174f7d7e2d4723e9fbfc40040dcb (patch) | |
tree | 7885b674d2deb064137f1f501ed1707bfd54daf8 /yaksh/c_cpp_files | |
parent | 1b71abc9437d721a41f017db406f312755f5a4c4 (diff) | |
parent | 2b03aeb36fa333ea1644a248c742cf0c1df12a5f (diff) | |
download | online_test-40fbb5d8f1d4174f7d7e2d4723e9fbfc40040dcb.tar.gz online_test-40fbb5d8f1d4174f7d7e2d4723e9fbfc40040dcb.tar.bz2 online_test-40fbb5d8f1d4174f7d7e2d4723e9fbfc40040dcb.zip |
rebase changes with stdio evaluator
Diffstat (limited to 'yaksh/c_cpp_files')
-rw-r--r-- | yaksh/c_cpp_files/file_data.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/yaksh/c_cpp_files/file_data.c b/yaksh/c_cpp_files/file_data.c new file mode 100644 index 0000000..1c0ab12 --- /dev/null +++ b/yaksh/c_cpp_files/file_data.c @@ -0,0 +1,25 @@ +#include <stdio.h> +#include <stdlib.h> + +extern int ans(); + +template <class T> +void check(T expect,T result) +{ + if (expect == result) + { + printf("\nCorrect:\n Expected %d got %d \n",expect,result); + } + else + { + printf("\nIncorrect:\n Expected %d got %d \n",expect,result); + exit (0); + } +} + +int main(void) +{ + int result; + result = ans(); + check(50, result); +} |