BlueBear icon

Untitled

BlueBear | PRO | 11/18/12 05:32:55 PM UTC | 0 ⭐ | 383 👁️ | Never ⏰ | []
C |

710 B

|

None

|

0 👍

/

0 👎

void najncena()
{
    FILE *fr;
    char p[POCET];
    int i,v,s;
    double min,cena,w;
    min=10000;
    if ((fr = fopen("zajazdy.txt", "r")) == NULL)
    {
        printf("Neotvoreny subor\n");
        return 1;
    }
    while (!(feof(fr)))
    {
        fgets(p,32,fr);
        fgets(p,32,fr);
        fgets(p,32,fr);
        fscanf(fr, "%d\n", &v);
        fscanf(fr, "%lf\n", &cena);
        fgets(p,32,fr);
        fscanf(fr, "%d\n", &s);
        if ((v==5)&&(min>(cena/s))&&(s!=0))
        {
            min=cena/s;
            w=cena;
        }
        
 
    }
    printf("%lf\n",w);
    if (fclose(fr)== EOF)
    {
        printf(" Subor sa nepodarilo zatvorit\n");
        return 1;
    }
 
}

Comments

  •  icon
    01/01/70 12:00:00 AM UTC
    Plain Text |

    0 B

    |

    👍

    /

    👎

    
        
  • Syutrsz icon
    03/31/26 11:01:31 PM UTC
    text |

    0 B

    |

    0 👍

    /

    0 👎

    Best t33n active cpx link daily updates!
     Copy and paste the link in a new browser tab and then hit enter!
     https://crazyporn.@xxx/members/157354/?asgtbndr=1&play=true&spon=adworld&zone=400
     Remove the @ 
  •  icon
    01/01/70 12:00:00 AM UTC
    Plain Text |

    0 B

    |

    👍

    /

    👎