Converts 2 fathoms to feet - C Language Basics

C examples for Language Basics:Hello World

Description

Converts 2 fathoms to feet

Demo Code

#include <stdio.h>
int main(void)
{
    int feet, fathoms;
    /*  w  w w.jav  a 2 s.com*/
    fathoms = 2;
    feet = 6 * fathoms;
    printf("There are %d feet in %d fathoms!\n", feet, fathoms);
    printf("Yes, I said %d feet!\n", 6 * fathoms);
    
    return 0;
}

Related Tutorials