[ create a new paste ] login | about

Link: http://codepad.org/qV4RpUB2    [ raw code | output | fork ]

C, pasted on Dec 13:
1
2
3
4
5
6
7
8
9
10
#include <stdio.h>
float x,ii,c;
int main(){
x=2;
ii=0;
c=3;
for(ii=0; ii<=16;ii+=c){
x=x^ii-log(ii);
}
printf("the final value for x is %f.\n",x)


Output:
1
2
3
4
5
In function 'main':
Line 8: warning: incompatible implicit declaration of built-in function 'log'
Line 8: error: invalid operands to binary ^
Line 10: error: expected ';' at end of input
Line 10: error: expected declaration or statement at end of input


Create a new paste based on this one


Comments: