查看單個文章
舊 2005-09-26, 09:58 PM   #8 (permalink)
天上天下
註冊會員
 
天上天下 的頭像
榮譽勳章

勳章總數0
UID - 3073
在線等級: 級別:1 | 在線時長:8小時 | 升級還需:4小時
註冊日期: 2002-12-06
VIP期限: 2005-12
文章: 89
精華: 0
現金: 1 金幣
資產: 1 金幣
預設

我直接貼出來好了


#include <stdio.h>
#include <stdlib.h>
main()
{
char ch;
int num;
float value;
printf("Enter two number:");
scanf("%d\n",&num);
scanf("%c",&ch);
value=(float)num/ch;
printf("%-6.2f",value);
system("PAUSE");
return 0;
}


輸入一個小寫字母,將其轉變成大寫後印出
#include<stdio.h>
#include<stdlib.h>
#include<ctype.h>
main()
{
char a;
toupper(a);
printf("input :");
scanf("%c",&a);
printf("input :%c",a=toupper(a));
system("PAUSE");
return 0;
}

由鍵盤輸入浮點數 2.5 及整數 3,印出兩者相乘與相除的結果。
#include <stdio.h>
#include <stdlib.h>
main()
{
float a,c;
int b;
printf("input a:");
scanf("%f",&a);
printf("input b:");
scanf("%d",&b);
printf("a*b=%f\n",a*b);
printf("a/b=%f\n",a/b);
system("PAUSE");
return 0;
}


snoopy大大,那個網站是您做的喔,之前在上課時在找資料時看到,
對我受益無窮說,可惜後來回家就找部到了,不過沒想到在這裡找到,真好運^^


另外怎麼我用Firefox瀏覽時怎麼內容的部份會出現無法連結的問題??
我用IE看就沒問題,我都是用Firefox在上網說
天上天下 目前離線  
送花文章: 4, 收花文章: 1 篇, 收花: 1 次
回覆時引用此帖