/* A program to compute the number of liters for 1, 2, ..., 12 quarts *
 * Version 2:  simple table with formatting of integers and reals     */

#include <stdio.h>

int main (void)
{   int quarts;
    double liters;

    printf (" Table of quart and liter equivalents\n\n");
    printf ("Quarts        Liters\n");


    for (quarts = 1; quarts <= 12; quarts++)
      { liters  = quarts / 1.056710 ;
        printf ("%4d%16.4f\n", quarts, liters);
        /* use 4-character width for printing the integer quarts,
           use 16-character width, with 4 places after the decimal point,
           for printing floating point number liters */
      }

    return 0;
}
