public class Solution
 {
     public static void main(String[] args)
     {
         System.out.printf("%s\t%s\t%s\t%s\n", "Inch", "Meter", "Meter", "Inch");

         for(double i = 1, j = 20; i <= 10 && j <= 65; i++, j += 5)
             System.out.printf("%f\t%f\t%f\t%f\n", i, footToMeter(i), j, meterToFoot(j));
     }

     public static double footToMeter(double foot)
     { return foot / 0.305; }

     public static double meterToFoot(double meter)
     { return meter * 0.305; }
 }

HW5.9的更多相关文章

  1. HW5.36

    import java.util.Scanner; public class Solution { public static void main(String[] args) { Scanner i ...

  2. HW5.35

    import java.util.Scanner; public class Solution { public static void main(String[] args) { Scanner i ...

  3. HW5.34

    import java.util.Scanner; public class Solution { public static void main(String[] args) { Scanner i ...

  4. HW5.33

    import java.util.Calendar; public class Solution { public static void main(String[] args) { long tot ...

  5. HW5.32

    public class Solution { public static void main(String[] args) { int n1 = (int)(Math.random() * 5 + ...

  6. HW5.31

    import java.util.Scanner; public class Solution { public static void main(String[] args) { Scanner i ...

  7. HW5.30

    public class Solution { public static void main(String[] args) { for(int i = 3; i <= 1000; i++) i ...

  8. HW5.29

    public class Solution { public static void main(String[] args) { int n1 = (int)(Math.random() * 5 + ...

  9. HW5.28

    public class Solution { public static void main(String[] args) { System.out.printf("%s\t%s\n&qu ...

  10. HW5.27

    public class Solution { public static void main(String[] args) { int totalCount = 0; int lineCount = ...

随机推荐

  1. MVC-各种传值方式

    [转自]:QLeelulu示例一:ViewData传值.HomeController.cs Co de: public ActionResult Index(){     ViewData[" ...

  2. hdu 2087 剪花布条 KMP多次匹配

    剪花布条 Problem Description 一块花布条,里面有些图案,另有一块直接可用的小饰条,里面也有一些图案.对于给定的花布条和小饰条,计算一下能从花布条中尽可能剪出几块小饰条来呢?   I ...

  3. C#运算符之与,或,异或及移位运算

    C#运算符之与,或,异或及移位运算 1.剖析异或运算(^) 二元 ^ 运算符是为整型和 bool 类型预定义的.对于整型,^ 将计算操作数的按位“异或”.对于 bool 操作数,^ 将计算操作数的逻辑 ...

  4. to debug asp.net mvc4

    Go to Tools -> Options -> Debugger -> General Uncheck the option Enable Just My Code (Manag ...

  5. sencha architect/sencha touch , to prevent breakpoint lost when you debug

    add this to your loader config: Ext.Loader.setConfig({ disableCaching: false }); or : click 'applica ...

  6. SQL语句中使用条件逻辑

    select name, sal, case when sal >= 4000 then 'Good' when sal <= 2000 then 'Bad' else 'Ok' end ...

  7. 从某一日期开始过day天的日期

    一个SX问我的,我就写了写......从2010.1.1开始,给了一组测试数据3的话输出2010.1.4星期1,所以说2010.1.1是星期五,总星期就是 (day+5)%7==0?7:(day+5) ...

  8. iOS 并发:NSOperation 与调度队列入门(1)

    一直以来,并发都被视为 iOS 开发中的「洪水猛兽」.许多开发者都将其视为危险地带,唯恐避之而不及.更有谣传认为,多线程代码应该尽力避免.笔者同意,如果你对并发的了解不够深入,就容易造成危险.但是,危 ...

  9. Java 8 vs. Scala(二):Stream vs. Collection

    [编者按]在之前文章中,我们介绍了 Java 8和Scala的Lambda表达式对比.在本文,将进行 Hussachai Puripunpinyo Java 和 Scala 对比三部曲的第二部分,主要 ...

  10. [string]Codeforces158C Cd and pwd commands

    题目链接 题意很清楚 和linux的语句是一样的 pwd输出路径 cd进入 ..回上一层目录 此题完全是string的应用 String的用法 vector<string> s; int ...