Run Code  | API  | Code Wall  | Misc  | Feedback  | Login  | Theme  | Privacy  | Patreon 

Max

Language: Layout:
+ ] Compiler args + ] Show input
Compilation time: 0.13 sec, absolute service time: 0,21 sec 
edit mode |  history  | discussion
Error(s):
source_file.c: In function ‘maxarray’:
source_file.c:11:19: error: invalid operands to binary & (have ‘int *’ and ‘int’)
         if ((array&(1<<(i+1)))>(array&(1<<i)))
                   ^
source_file.c:11:38: error: invalid operands to binary & (have ‘int *’ and ‘int’)
         if ((array&(1<<(i+1)))>(array&(1<<i)))
                                      ^
source_file.c:13:25: error: invalid operands to binary & (have ‘int *’ and ‘int’)
             max = (array&(1<<(i+1)));
                         ^
source_file.c:17:25: error: invalid operands to binary & (have ‘int *’ and ‘int’)
             max = (array&(1<<i));
                         ^
source_file.c: In function ‘main’:
source_file.c:29:13: warning: passing argument 1 of ‘sprintf’ from incompatible pointer type [-Wincompatible-pointer-types]
     sprintf(Array, "12345");
             ^
In file included from /usr/include/features.h:367:0,
                 from /usr/include/stdio.h:27,
                 from source_file.c:3:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:31:1: note: expected ‘char * restrict’ but argument is of type ‘int *’
 __NTH (sprintf (char *__restrict __s, const char *__restrict __fmt, ...))
 ^

        

    
                
λ
.NET NoSQL database for rapid development