導航:首頁 > 數據分析 > 頂展數據c象限什麼意思

頂展數據c象限什麼意思

發布時間:2023-06-17 02:50:01

❶ 編程 輸入一平面坐標點(x,y),判斷並輸出該坐標點位於哪個象限c語言

#include<stdio.h>

int x,y;
char *output[20];
int p;

void main(){
printf("請輸入一個坐標如:3,3\n");
while(scanf("%d,%d",&x,&y)!=EOF)
{

if(x > 0 && y > 0)
p=1;
else if(x > 0 && y < 0)
p=4;
else if(x < 0 && y > 0)
p=2;
else if(x < 0 && y < 0)
p=3;

switch(p){
case 1:*output = "第一象限\n";break;
case 4:*output = "第四象限\n";break;
case 2:*output = "第二象限\n";break;
case 3:*output = "第三象限\n";break;
}
printf("%s",*output);
}
}

閱讀全文

與頂展數據c象限什麼意思相關的資料

熱點內容
excel表格文件化亂碼 瀏覽:986
win7無法打開隱藏文件 瀏覽:757
怎樣把壓縮文件變成空白文件 瀏覽:516
wokrNC和UG編程哪個好 瀏覽:487
愛奇藝隨刻文件名 瀏覽:40
wps是怎麼壓縮文件 瀏覽:986
dos配置文件名 瀏覽:582
java軟體工程師做什麼 瀏覽:897
3dmax導出ive文件 瀏覽:464
數據重復性好是什麼意思 瀏覽:166
如何查找電腦文件使用歷史記錄 瀏覽:821
linux可以運行exe的文件嗎 瀏覽:935
庫幣是哪個國家的app 瀏覽:201
大智慧internet文件夾有哪些文件 瀏覽:89
編程培訓課程哪個排名好 瀏覽:124
我的cad怎麼沒顯示文件選項卡 瀏覽:952
命令行當前是哪個資料庫 瀏覽:588
為什麼appstore打開空白 瀏覽:574
選貨車軟體什麼app最好 瀏覽:577
psv仙境傳說ace如何降級版本 瀏覽:460

友情鏈接