Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
HW4e5
#include <stdio.h> int main() { int n, i,a, min1, min2; scanf("%d", & n) ; scanf("%d", & a) ; min1=a-1; min2=a; for(i=1;i<n;i++) { scanf("%d",&a) ; if(min1>a) { min1=a; } else if(min1<min2 && min2>a) { min2=a; } } printf("%d", min2) ; return 0; }
run
|
edit
|
history
|
help
0
numerodevecesquerepitedigitoennumero
gcc compiler bug.. weird.
Volume of a square pyramid With functions
fibonacci2
Prgm
Assignment 4 v3
MatrixMul_shortxshort
scanf and integer manipulation
Test 3
C Pointers Experiment (So bad don't use)