#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, float *);
int main() {
  float a, b, x, y, bica_a, bica_b, ralo_a, ralo_b;
  int h = 0;
  do {
    printf("entre com a quantidade x de litros: ");
    scanf("%f", &x);
    printf("entre com a quantidade y de litros: ");
    scanf("%f", &y);
  } while (x < 0 && y < 0);
  do {
    printf("entre com a quantidade C de litros por hora: ");
    scanf("%f", &bica_a);
    printf("entre com a quantidade D em litros por minuto: ");
    scanf("%f", &ralo_a);
    ralo_a = ralo_a * 60;
  } while (ralo_a < bica_a);
  do {
    printf("entre com a quantidade E de litros por hora: ");
    scanf("%f", &bica_b);
    printf("entre com a quantidade F em litros por minuto: ");
    scanf("%f", &ralo_b);
    ralo_b = ralo_b * 60;
  } while (ralo_b < bica_b);
  while (x >= 0 && y >= 0) {
    x = x + bica_a - ralo_a;
    y = y + bica_b - ralo_b;
    h++;
  }
  if (x < y)
    printf("tamque A em %d horas\n", h);
  else if (y < x)
    printf("tamque B em %d horas\n", h);
  else if (y == x)
    printf("ao mesmo tempo\n", h);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x28(%rbp)
lea    0xec7(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xede(%rip),%rdi
lea    -0x10(%rbp),%rsi
call   1040 <scanf@plt>
lea    0xed1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xec0(%rip),%rdi
lea    -0x14(%rbp),%rsi
call   1040 <scanf@plt>
xor    %eax,%eax
xorps  %xmm0,%xmm0
ucomiss -0x10(%rbp),%xmm0
mov    %al,-0x29(%rbp)
jbe    1191 <main+0x71>
xorps  %xmm0,%xmm0
ucomiss -0x14(%rbp),%xmm0
seta   %al
mov    %al,-0x29(%rbp)
mov    -0x29(%rbp),%al
test   $0x1,%al
jne    1136 <main+0x16>
jmp    11a1 <main+0x81>
lea    0xea9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe73(%rip),%rdi
lea    -0x18(%rbp),%rsi
call   1040 <scanf@plt>
lea    0xeb9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe55(%rip),%rdi
lea    -0x20(%rbp),%rsi
call   1040 <scanf@plt>
movss  0xe1b(%rip),%xmm0
mulss  -0x20(%rbp),%xmm0
movss  %xmm0,-0x20(%rbp)
movss  -0x20(%rbp),%xmm1
movss  -0x18(%rbp),%xmm0
ucomiss %xmm1,%xmm0
ja     11a1 <main+0x81>
jmp    1207 <main+0xe7>
lea    0xea1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe0d(%rip),%rdi
lea    -0x1c(%rbp),%rsi
call   1040 <scanf@plt>
lea    0xeb1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xdef(%rip),%rdi
lea    -0x24(%rbp),%rsi
call   1040 <scanf@plt>
movss  0xdb5(%rip),%xmm0
mulss  -0x24(%rbp),%xmm0
movss  %xmm0,-0x24(%rbp)
movss  -0x24(%rbp),%xmm1
movss  -0x1c(%rbp),%xmm0
ucomiss %xmm1,%xmm0
ja     1207 <main+0xe7>
jmp    126d <main+0x14d>
movss  -0x10(%rbp),%xmm0
xor    %eax,%eax
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
mov    %al,-0x2a(%rbp)
jb     1294 <main+0x174>
movss  -0x14(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomiss %xmm1,%xmm0
setae  %al
mov    %al,-0x2a(%rbp)
mov    -0x2a(%rbp),%al
test   $0x1,%al
jne    12a4 <main+0x184>
jmp    12da <main+0x1ba>
movss  -0x10(%rbp),%xmm0
addss  -0x18(%rbp),%xmm0
subss  -0x20(%rbp),%xmm0
movss  %xmm0,-0x10(%rbp)
movss  -0x14(%rbp),%xmm0
addss  -0x1c(%rbp),%xmm0
subss  -0x24(%rbp),%xmm0
movss  %xmm0,-0x14(%rbp)
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    126d <main+0x14d>
movss  -0x10(%rbp),%xmm1
movss  -0x14(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jbe    1303 <main+0x1e3>
mov    -0x28(%rbp),%esi
lea    0xe16(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    135c <main+0x23c>
movss  -0x14(%rbp),%xmm1
movss  -0x10(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jbe    132c <main+0x20c>
mov    -0x28(%rbp),%esi
lea    0xe03(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1357 <main+0x237>
movss  -0x14(%rbp),%xmm0
ucomiss -0x10(%rbp),%xmm0
jne    1352 <main+0x232>
jp     1352 <main+0x232>
mov    -0x28(%rbp),%esi
lea    0xdee(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1357 <main+0x237>
jmp    135c <main+0x23c>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x20,%rsp
lea    0xec0(%rip),%r14
lea    0xede(%rip),%rbx
lea    0x10(%rsp),%r15
lea    0xed5(%rip),%r12
lea    0xc(%rsp),%r13
nopl   0x0(%rax)
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1050 <scanf@plt>
mov    %r12,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r13,%rsi
call   1050 <scanf@plt>
xorps  %xmm0,%xmm0
ucomiss 0x10(%rsp),%xmm0
jbe    119b <main+0x6b>
ucomiss 0xc(%rsp),%xmm0
ja     1160 <main+0x30>
lea    0xeaf(%rip),%r14
lea    0xe80(%rip),%rbx
lea    0x18(%rsp),%r15
lea    0xeca(%rip),%r12
lea    0x8(%rsp),%r13
nopw   0x0(%rax,%rax,1)
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1050 <scanf@plt>
mov    %r12,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r13,%rsi
call   1050 <scanf@plt>
movss  0xe0e(%rip),%xmm1
movss  0x8(%rsp),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,0x8(%rsp)
movss  0x18(%rsp),%xmm1
ucomiss %xmm0,%xmm1
ja     11c0 <main+0x90>
lea    0xe9b(%rip),%r14
lea    0xe0e(%rip),%rbx
lea    0x1c(%rsp),%r15
lea    0xeb6(%rip),%r12
lea    0x14(%rsp),%r13
nopl   0x0(%rax)
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
call   1050 <scanf@plt>
mov    %r12,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r13,%rsi
call   1050 <scanf@plt>
movss  0x14(%rsp),%xmm2
mulss  0xd98(%rip),%xmm2
movss  %xmm2,0x14(%rsp)
movss  0x1c(%rsp),%xmm3
ucomiss %xmm2,%xmm3
ja     1230 <main+0x100>
movss  0x10(%rsp),%xmm0
movss  0xc(%rsp),%xmm1
xor    %esi,%esi
xorps  %xmm4,%xmm4
ucomiss %xmm4,%xmm0
jb     12d9 <main+0x1a9>
ucomiss %xmm4,%xmm1
jb     12d9 <main+0x1a9>
movss  0x18(%rsp),%xmm4
xor    %esi,%esi
movss  0x8(%rsp),%xmm5
xorps  %xmm6,%xmm6
cs nopw 0x0(%rax,%rax,1)
nop
addss  %xmm4,%xmm0
subss  %xmm5,%xmm0
addss  %xmm3,%xmm1
subss  %xmm2,%xmm1
add    $0x1,%esi
ucomiss %xmm6,%xmm0
jb     12cd <main+0x19d>
ucomiss %xmm6,%xmm1
jae    12b0 <main+0x180>
movss  %xmm0,0x10(%rsp)
movss  %xmm1,0xc(%rsp)
ucomiss %xmm0,%xmm1
jbe    12e7 <main+0x1b7>
lea    0xe28(%rip),%rdi
jmp    12f3 <main+0x1c3>
ucomiss %xmm1,%xmm0
jbe    130a <main+0x1da>
lea    0xe30(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
ret
ucomiss %xmm0,%xmm1
jne    12fa <main+0x1ca>
jp     12fa <main+0x1ca>
lea    0xe21(%rip),%rdi
call   1030 <puts@plt>
jmp    12fa <main+0x1ca>

LLVM IR (-O0):
@.str = [37 x i8] c"entre com a quantidade x de litros: \00"
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [37 x i8] c"entre com a quantidade y de litros: \00"
@.str.3 = [46 x i8] c"entre com a quantidade C de litros por hora: \00"
@.str.4 = [48 x i8] c"entre com a quantidade D em litros por minuto: \00"
@.str.5 = [46 x i8] c"entre com a quantidade E de litros por hora: \00"
@.str.6 = [48 x i8] c"entre com a quantidade F em litros por minuto: \00"
@.str.7 = [22 x i8] c"tamque A em %d horas\0A\00"
@.str.8 = [22 x i8] c"tamque B em %d horas\0A\00"
@.str.9 = [16 x i8] c"ao mesmo tempo\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca float
%6 = alloca float
%7 = alloca float
%8 = alloca float
%9 = alloca float
%10 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %10
br label %11
11: ; preds = %22, %0
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
%13 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %4)
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0))
%15 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %5)
br label %16
16: ; preds = %11
%17 = load float, float* %4
%18 = fcmp olt float %17, 0.000000e+00
br i1 %18, label %19, label %22
19: ; preds = %16
%20 = load float, float* %5
%21 = fcmp olt float %20, 0.000000e+00
br label %22
22: ; preds = %19, %16
%23 = phi i1 [ false, %16 ], [ %21, %19 ]
br i1 %23, label %11, label %24
24: ; preds = %22
br label %25
25: ; preds = %32, %24
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.3, i64 0, i64 0))
%27 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %6)
%28 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.4, i64 0, i64 0))
%29 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %8)
%30 = load float, float* %8
%31 = fmul float %30, 6.000000e+01
store float %31, float* %8
br label %32
32: ; preds = %25
%33 = load float, float* %8
%34 = load float, float* %6
%35 = fcmp olt float %33, %34
br i1 %35, label %25, label %36
36: ; preds = %32
br label %37
37: ; preds = %44, %36
%38 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.5, i64 0, i64 0))
%39 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %7)
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.6, i64 0, i64 0))
%41 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %9)
%42 = load float, float* %9
%43 = fmul float %42, 6.000000e+01
store float %43, float* %9
br label %44
44: ; preds = %37
%45 = load float, float* %9
%46 = load float, float* %7
%47 = fcmp olt float %45, %46
br i1 %47, label %37, label %48
48: ; preds = %44
br label %49
49: ; preds = %57, %48
%50 = load float, float* %4
%51 = fcmp oge float %50, 0.000000e+00
br i1 %51, label %52, label %55
52: ; preds = %49
%53 = load float, float* %5
%54 = fcmp oge float %53, 0.000000e+00
br label %55
55: ; preds = %52, %49
%56 = phi i1 [ false, %49 ], [ %54, %52 ]
br i1 %56, label %57, label %70
57: ; preds = %55
%58 = load float, float* %4
%59 = load float, float* %6
%60 = fadd float %58, %59
%61 = load float, float* %8
%62 = fsub float %60, %61
store float %62, float* %4
%63 = load float, float* %5
%64 = load float, float* %7
%65 = fadd float %63, %64
%66 = load float, float* %9
%67 = fsub float %65, %66
store float %67, float* %5
%68 = load i32, i32* %10
%69 = add nsw i32 %68, 1
store i32 %69, i32* %10
br label %49
70: ; preds = %55
%71 = load float, float* %4
%72 = load float, float* %5
%73 = fcmp olt float %71, %72
br i1 %73, label %74, label %77
74: ; preds = %70
%75 = load i32, i32* %10
%76 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.7, i64 0, i64 0), i32 %75)
br label %93
77: ; preds = %70
%78 = load float, float* %5
%79 = load float, float* %4
%80 = fcmp olt float %78, %79
br i1 %80, label %81, label %84
81: ; preds = %77
%82 = load i32, i32* %10
%83 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.8, i64 0, i64 0), i32 %82)
br label %92
84: ; preds = %77
%85 = load float, float* %5
%86 = load float, float* %4
%87 = fcmp oeq float %85, %86
br i1 %87, label %88, label %91
88: ; preds = %84
%89 = load i32, i32* %10
%90 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0), i32 %89)
br label %91
91: ; preds = %88, %84
br label %92
92: ; preds = %91, %81
br label %93
93: ; preds = %92, %74
ret i32 0
}

LLVM IR (-O2):
@.str = [37 x i8] c"entre com a quantidade x de litros: \00"
@.str.1 = [3 x i8] c"%f\00"
@.str.2 = [37 x i8] c"entre com a quantidade y de litros: \00"
@.str.3 = [46 x i8] c"entre com a quantidade C de litros por hora: \00"
@.str.4 = [48 x i8] c"entre com a quantidade D em litros por minuto: \00"
@.str.5 = [46 x i8] c"entre com a quantidade E de litros por hora: \00"
@.str.6 = [48 x i8] c"entre com a quantidade F em litros por minuto: \00"
@.str.7 = [22 x i8] c"tamque A em %d horas\0A\00"
@.str.8 = [22 x i8] c"tamque B em %d horas\0A\00"
@str = [15 x i8] c"ao mesmo tempo\00"
define i32 @main() {
%1 = alloca float
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = alloca float
%6 = alloca float
%7 = bitcast float* %1 to i8*
%8 = bitcast float* %2 to i8*
%9 = bitcast float* %3 to i8*
%10 = bitcast float* %4 to i8*
%11 = bitcast float* %5 to i8*
%12 = bitcast float* %6 to i8*
br label %13
13: ; preds = %13, %0
%14 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
%15 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %1)
%16 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str.2, i64 0, i64 0))
%17 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %2)
%18 = load float, float* %1
%19 = fcmp olt float %18, 0.000000e+00
%20 = load float, float* %2
%21 = fcmp olt float %20, 0.000000e+00
%22 = select i1 %19, i1 %21, i1 false
br i1 %22, label %13, label %23
23: ; preds = %13, %23
%24 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([46 x i8], [46 x i8]* @.str.3, i64 0, i64 0))
%25 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %3)
%26 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @.str.4, i64 0, i64 0))
%27 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %5)
%28 = load float, float* %5
%29 = fmul float %28, 6.000000e+01
store float %29, float* %5
%30 = load float, float* %3
%31 = fcmp olt float %29, %30
br i1 %31, label %23, label %32
32: ; preds = %23, %32
%33 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([46 x i8], [46 x i8]* @.str.5, i64 0, i64 0))
%34 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %4)
%35 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @.str.6, i64 0, i64 0))
%36 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), float* %6)
%37 = load float, float* %6
%38 = fmul float %37, 6.000000e+01
store float %38, float* %6
%39 = load float, float* %4
%40 = fcmp olt float %38, %39
br i1 %40, label %32, label %41
41: ; preds = %32
%42 = load float, float* %1
%43 = load float, float* %2
%44 = fcmp oge float %42, 0.000000e+00
%45 = fcmp oge float %43, 0.000000e+00
%46 = select i1 %44, i1 %45, i1 false
br i1 %46, label %47, label %63
47: ; preds = %41
%48 = load float, float* %3
%49 = load float, float* %5
br label %50
50: ; preds = %47, %50
%51 = phi i32 [ 0, %47 ], [ %58, %50 ]
%52 = phi float [ %42, %47 ], [ %55, %50 ]
%53 = phi float [ %43, %47 ], [ %57, %50 ]
%54 = fadd float %52, %48
%55 = fsub float %54, %49
%56 = fadd float %39, %53
%57 = fsub float %56, %38
%58 = add nuw nsw i32 %51, 1
%59 = fcmp oge float %55, 0.000000e+00
%60 = fcmp oge float %57, 0.000000e+00
%61 = select i1 %59, i1 %60, i1 false
br i1 %61, label %50, label %62
62: ; preds = %50
store float %55, float* %1
store float %57, float* %2
br label %63
63: ; preds = %62, %41
%64 = phi i32 [ %58, %62 ], [ 0, %41 ]
%65 = phi float [ %55, %62 ], [ %42, %41 ]
%66 = phi float [ %57, %62 ], [ %43, %41 ]
%67 = fcmp olt float %65, %66
br i1 %67, label %68, label %70
68: ; preds = %63
%69 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.7, i64 0, i64 0), i32 %64)
br label %78
70: ; preds = %63
%71 = fcmp olt float %66, %65
br i1 %71, label %72, label %74
72: ; preds = %70
%73 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @.str.8, i64 0, i64 0), i32 %64)
br label %78
74: ; preds = %70
%75 = fcmp oeq float %66, %65
br i1 %75, label %76, label %78
76: ; preds = %74
%77 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str, i64 0, i64 0))
br label %78
78: ; preds = %72, %76, %74, %68
ret i32 0
}