herrDeng網內搜尋
自訂搜尋
Ads
訂閱:
張貼留言 (Atom)
熱門文章
-
教育部為提昇全民資安素養與電腦防護能力,本部於101年9月5日至11月5日舉辦「全民資安素養自我評量」活動,請在活動期間內踴躍上網檢測資訊安全素養認知程度,並有機會參與抽獎,詳情請參閱活動網站(網址: https://isafe.moe.edu.tw/event
-
url="https://www.twse.com.tw/exchangeReport/STOCK_DAY?response=json&date=20220330&stockNo=2330"
-
XOR prefixsum CPP python解Leetcode 1829 Maximum XOR for Each Query 其實這裡考慮的是元素個數為2^maximumBit的交換群,運算子為XOR。 [Python code請進]
-
你會用C的算子sizeof?
-
Python C++使用字串find迴圈速解Leetcode 2490 Circular Sentence C++ & Python都有字串的find,用法都類似 split=s.find(' ', split+1)能找到s從index=split+1開...
-
先說明一下這是後知後覺的解答,所謂後知就是股票價格已知存在陣列(清單),當然就要用迴圈練習,雙迴圈暴力解需時O(n**2),當然不用,採python單一迴圈解答「最佳股票的買賣時機#LeetCode 121 Best Time to Buy and Sell Stock」,解...
-
Colab上安裝中文字型修改股市爬蟲pyplot顯圖 使用python套件: numpy, requests. pyplot, matplotlib.font_manager, matplotlib.mpl
-
2 pointer Python C++解Leetcode 3163 String Compression III [codes on Leetcode] https://leetcode.com/problems/string-compression-iii/solution...
64 則留言:
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=174, w=103, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();
h = Convert.ToDouble(tmp);
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();
w = Convert.ToDouble(tmp);
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace bmi
{
class Program
{
static void Main(string[] args)
{
int m = 178;
int w = 79;
string temp;
Console.WriteLine("m=");
temp = Console.ReadLine();
m = Convert.ToInt32(temp);
Console.WriteLine("m=" + m);
Console.Write("w=");
temp = Console.ReadLine();
w = Convert.ToInt32(temp);
Console.WriteLine("w=" + w);
double bmi = 10000.0 * w / m / m;
Console.WriteLine("bmi=" + bmi);
Console.Read();
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("毛聖翔帥哥\n");
double h=173, w=54, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=167, w=60, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=170, w=49, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp2//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace _2202020//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=185, w=90, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//轉資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//轉資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace bmi
{
class Program
{
static void Main(string[] args)
{
int m = 178;
int w = 79;
string temp;
Console.WriteLine("m=");
temp = Console.ReadLine();
m = Convert.ToInt32(temp);
Console.WriteLine("m=" + m);
Console.Write("w=");
temp = Console.ReadLine();
w = Convert.ToInt32(temp);
Console.WriteLine("w=" + w);
double bmi = 10000.0 * w / m / m;
Console.WriteLine("bmi=" + bmi);
Console.Read();
using System;
namespace bmi
{
class Program
{
static void Main(string[] args)//主程式
{
int h = 178;//宣告變數
int w = 79;
string temp;
Console.Write("h=");
temp = Console.ReadLine();//讀資訊
h = Convert.ToInt32(temp);//轉型態
Console.WriteLine("h=" + h);
Console.Write("w=");
temp = Console.ReadLine();//讀資訊
w = Convert.ToInt32(temp);//轉型態
Console.WriteLine("w=" + w);
double bmi = 10000.0 * w / h / h;
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace T0304//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace project0304//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace BMI//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp2//命名空間
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=169, w=60, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199,w=100,bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("Force 1096\n");
Double h=180, w=69, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("W=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace project02//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=172, w=65, bmi;//宣告變數
String tmp;
Console.WriteLine("h=");//讀資訊
tmp = Console.ReadLine();//轉型態
h = Convert.ToDouble(tmp);
Console.WriteLine(h);
Console.WriteLine("w=");//讀資訊
tmp = Console.ReadLine();//轉型態
w = Convert.ToDouble(tmp);
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=160, w=48, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute bmi\n");
double h=170, w=95, bmi;//宣告變數
string tmp;
Console.WriteLine("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.WriteLine("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace baibaideApp1//命名空間
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=160, W=58, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
W = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(W);
h = h / 100;
bmi = W / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace _20200304//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=150, w=43, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=174, w=103, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();
h = Convert.ToDouble(tmp);
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();
w = Convert.ToDouble(tmp);
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("Compute Bmi\n");
double h=180, w=70, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=170, w=60, bmi;//宣告變數
string tmp;
Console.Write("h=");//讀資訊
tmp = Console.ReadLine();//轉型態
h = Convert.ToDouble(tmp);
Console.WriteLine(h);
Console.Write("w=");//讀資訊
tmp = Console.ReadLine();//轉型態
w = Convert.ToDouble(tmp);
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi); //輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=166, w=50, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" +bmi);//輸出結果
Console.Read();
}
}
}
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199,w=100,bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
using System;//命名空間
namespace ConsoleApp2//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
namespace ConsoleApp1//命名空間
{
class Program//分類
{
static void Main(string[] args)//主程式
{
Console.Write("嘎\n");
Double h=174, w=56, bmi;//宣告變數
string tmp;
Console.Write("w=");
tmp = Console.ReadLine();
w = Convert.ToDouble(tmp);
Console.WriteLine(h);
Console.Write("h=");
tmp = Console.ReadLine();
h = Convert.ToDouble(tmp);
Console.WriteLine(h);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//結果
Console.Read();
using System;
namespace BMI
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp2
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("Compute Bmi \n");
double h = 200, w = 100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("Compute Bmi \n");
double h=178, w=68, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=175, w=50, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=165, w=60, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BMI
{
class Program//BMI
{
static void Main(string[] args)//主程式
{
Console.Write("左邊那位");
int m = 173; //宣告變數
int w = 87; //宣告變數
string temp;
Console.Write("m=");
temp= Console.ReadLine();//讀資料
m = Convert.ToInt32(temp);//轉型態
Console.WriteLine("m=" +m);
Console.Write("w=");
temp = Console.ReadLine();
w = Convert.ToInt32(temp);
Console.WriteLine("w=" +w);
double bmi = 10000.0 * w / m / m;
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)
{
int m = 178;
int w = 79;
string temp;
Console.Write("m=");
temp = Console.ReadLine();
m = Convert.ToInt32(temp);
Console.WriteLine("m=" + m);
Console.WriteLine("w=");
temp = Console.ReadLine();
w = Convert.ToInt32(temp);
Console.WriteLine("w=" + w);
Double bmi = 10000.0 * w / m / m;
Console.WriteLine("bmi=" + bmi);
Console.Read();
}
}
}
using System;//BMI
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace bmi_1
{
class Program//BMI
{
static void Main(string[] args)//主程式
{
Console.WriteLine("右邊那位");
int m =183;//宣告變數
int w =60;//宣告變數
string temp;
Console.Write("m=");
temp = Console.ReadLine();//讀資訊
m = Convert.ToInt32(temp);//轉形態
Console.WriteLine("m="+m);
Console.Write("w=");
temp = Console.ReadLine();//讀資訊
w = Convert.ToInt32(temp);//轉形態
Console.WriteLine("w="+w);
double bmi = 10000.0 * w / m / m;//BMI公式
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace BMI
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=180, w=75, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);
Console.Read();
}
}
}
using System;
namespace ConsoleApp2
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h = 199,w =100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace BMI
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=180, w=75, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);
Console.Read();
}
}
}
using System;//命名空間
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=165, w=68, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace ComsoleAppl//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.WriteLine("compute Bmi\n");
double h=179,w=60,bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();
w = Convert.ToDouble(tmp);
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp2//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h =199, w =100, bmi;//宣告變數
string tmp;//宣告字串變數
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
using System;
namespace ConsoleApp2
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h = 199,w =100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace _0405
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("Hello World!\n");
double h=169, w=54, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp =Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);
Console.Read();
}
}
}
using System;
namespace ComsoleAppl//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.WriteLine("compute Bmi\n");
double h=179,w=60,bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();
w = Convert.ToDouble(tmp);
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace Project02//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace project02//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace BMI//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
using System;//命名空間
namespace Program02//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compule Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //讀型態
Console.WriteLine(h);
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //讀型態
Console.WriteLine(h);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace project02//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");//宣告變數
double h = 172, w = 75, bmi;
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h= Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=170, w=53, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace Program02//命名空間
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉機型
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace Console//命名空間
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.Write("bmi" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace ConsoleApp1//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=170, w=49, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;
namespace ConsoleApp2
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h = 199,w =100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
w = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
namespace BMI//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
int h = 195;
int w = 80;
string temp;
//宣告變數
Console.Write("h=");
temp = Console.ReadLine();//讀資訊
h = Convert.ToInt32(temp);//轉型態
Console.WriteLine("h=" + h);
Console.Write("w=");
temp = Console.ReadLine();//讀資訊
w = Convert.ToInt32(temp);//轉型態
Console.WriteLine("w=" + w);
double bmi = 10000.0 * w / h / h;
Console.WriteLine("bmi="+bmi);//輸出結果
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("computc Bmi \n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("computc Bmi \n");
double h=180, w=190, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("computc Bmi \n");
double h=169, w=95, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class Program
{
static void Main(string[] args)//主程式
{
Console.Write("computc Bmi \n");
double h=189, w=105, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine(); //讀資訊
h = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine(); //讀資訊
w = Convert.ToDouble(tmp); //轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp2//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
using System;//命名空間
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp2//命名空間
{
class Program//類別
{
static void Main(string[] args)//主程式
{
Console.Write("compute Bmi\n");
double h=199, w=100, bmi;//宣告變數
string tmp;
Console.Write("h=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(h);
Console.Write("w=");
tmp = Console.ReadLine();//讀資訊
h = Convert.ToDouble(tmp);//轉型態
Console.WriteLine(w);
h = h / 100;
bmi = w / (h * h);
Console.WriteLine("bmi=" + bmi);//輸出結果
Console.Read();
}
}
}
張貼留言