1 2 3 4 5 6 7 8 9 10
// Example 4.10, page no-212 clear clc Ww=12-2 dw=1000 v=Ww/dw dx=(10-2)/v sg=dx/dw printf("Specific Gravity of X =%.1f",sg)