/*********************************************************** tall.ch Introduction to Ch This program introduces how to read multiple input from the user and store the input into a variable. ************************************************************ Copyright 2014 SoftIntegration Inc. http://www.softintegration.com Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 ***********************************************************/ // initialize variables int feet, inches; double totalinches, totalfeet; // ask user for input printf("enter your height as follows: feet, inches: "); scanf("%d, %d", &feet, &inches); // compute total inches and total feet totalinches = feet*12 + inches; totalfeet = feet+inches/12.0; // prints the answer to the screen printf("You are %lf inches tall.\n", totalinches); printf("You are %lf feet tall.\n", totalfeet);