Subversion Repositories svnkaklik

Rev

Go to most recent revision | Details | Last modification | View Log

Rev Author Line No. Line
160 kaklik 1
#include <stdio.h>
2
 
3
 
161 kaklik 4
float nejvetsi (float a,float b,float c)
160 kaklik 5
{
6
  if (a>b)
7
  {
8
    if (a>c) return (a);
9
  }
10
  else
11
  {
12
    if (b>c) return (b);
13
	else return (c);
14
  }
15
}
16
 
17
int main (void)
18
{
19
  float a,b,c=0;
20
  				// zadej hodnoty
21
  printf("\n Zadej hodnotu a= ");
22
  scanf("%f",&a);
23
  printf("\n Zadej hodnotu b= ");
24
  scanf("%f",&b);
25
  printf("\n Zadej hodnotu c= ");
26
  scanf("%f",&c);
27
 
28
  printf("nejvetsi hodnota je %f",nejvetsi(a,b,c));
29
 
30
}