一道c語言題,大小寫轉換,一道C語言題,大小寫轉換

2021-12-16 20:12:15 字數 816 閱讀 1569

1樓:am蘑菇

首先,lz你這不是大小寫轉換,至少要你轉為大寫字母你這程式轉不了.我現在幫你改了下.

#include

int main( void )

2樓:

scanf("%d",c1);

scanf("%c",&c1);

請注意你寫的是char所以不能輸入65。應該直接寫a。就可以了。你試一下。肯定可以了。讓你繞的

要輸入65應該這樣

#include

#include

main()

3樓:

vc++是要寫抬頭的。using namespace std;#include

問題補充中,

if(c1>=65&&c1<=90)

c1=c1+32;

這不是應該 c1=c1-32;的麼?

4樓:匿名使用者

scanf(「%d」,c1)改為scanf("%c",&c1)while 改為 if。 且後面的分號去掉。

#include

void main()

5樓:匿名使用者

scanf("%c",&c1);

%d是int型。

6樓:匿名使用者

char c1,已經規定了字元型,可是你在scanf("d")這裡錯了,把「%d改為%c就可以

7樓:匿名使用者

scanf("%c",&c1); char c1寫最前面

c語言字元大小寫轉換C語言字元大小寫轉換

內容來自使用者 5042350423 include using namespace std 將字串中小寫字母轉換為大寫字母 char letter strupr char s return p 將字串中大寫字母轉換為小寫字母 char letter strlwr char s return p i...

一道C語言程式設計題,一道C語言程式設計題

include include define change 0 int main void 你的串號我已經記下,採納後我會幫你製作 應該算是比較完整的程式了,如果你的問題還有補充的話請告訴我.author banxi1988 date 2010 12 9 include include define...

c語言小白求解一道題,C語言小白求解一道題。

include include int main if num 10 2 while num printf 是偶數reverse d n reverse return 0 include include int odd int num 對num第二位進行判斷奇偶性,是奇數則返回1偶數返回0 int ...