Re: [問題] 九九乘法表不用迴圈是叫我直接從1列到81?

看板C_and_CPP作者 (阿貓)時間5年前 (2018/07/16 19:16), 5年前編輯推噓3(306)
留言9則, 9人參與, 5年前最新討論串3/29 (看更多)
#include <assert.h> #include <stdio.h> #include <curl/curl.h> int main(void) { CURL* curl = curl_easy_init(); assert(curl); assert(CURLE_OK == curl_easy_setopt(curl, CURLOPT_URL, "https://pastebin.com/raw/L4jHxUTA")); assert(CURLE_OK == curl_easy_setopt(curl, CURLOPT_WRITEDATA, stdout)); assert(CURLE_OK == curl_easy_perform(curl)); curl_easy_cleanup(curl); return 0; } // link with -lcurl (咦? ※ 引述《cutekid (可愛小孩子)》之銘言: : Goto版(但沒直接用Goto關鍵字): : #include <stdio.h> : #include <setjmp.h> : jmp_buf buf; : int main(void) { : int i = setjmp(buf) ; : if(i < 81){ : printf("%d x %d = %2d\n", i/9+1, i%9+1, (i/9+1) * (i%9+1)); : longjmp(buf,i + 1); : } : return 0; : } : ※ 引述《red0whale (red whale)》之銘言: : : 剛才做題目, : : https://i.imgur.com/NI4TYj5.jpg
: : 九九乘法表用兩個或一個迴圈來做我都會 : : 但不用迴圈叫我列九九乘法表是哪招? : : 難道是要我直接從1*1列到9*9嗎? : : 還是其實有妙招? : : 說實在我真想不到不用迴圈就能簡單列出九九乘法表的方法了 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 140.113.193.217 ※ 文章網址: https://www.ptt.cc/bbs/C_and_CPP/M.1531739804.A.6A7.html ※ 編輯: PkmX (140.113.193.217), 07/16/2018 19:21:51

07/16 19:37, 5年前 , 1F
連CURL都有 x_x
07/16 19:37, 1F

07/16 20:29, 5年前 , 2F
...
07/16 20:29, 2F

07/16 21:00, 5年前 , 3F
這會變成系列文嗎 XDDDD
07/16 21:00, 3F

07/16 22:00, 5年前 , 4F
有時覺得系列惡搞文比伸手文更糟糕...
07/16 22:00, 4F

07/16 22:54, 5年前 , 5F
我...我看這篇才知道可以不摳curl_global_init
07/16 22:54, 5F

07/16 23:13, 5年前 , 6F
現在大家都活在網路世代,先學習 libcurl 有備無患。
07/16 23:13, 6F

07/17 10:40, 5年前 , 7F
.....
07/17 10:40, 7F

07/17 11:51, 5年前 , 8F
libcurl 真的是好物 (咦)
07/17 11:51, 8F

07/24 16:46, 5年前 , 9F
curl: 我也是看報紙才知道,我也會寫 9 x 9 ...
07/24 16:46, 9F
文章代碼(AID): #1RJ7wSQd (C_and_CPP)
討論串 (同標題文章)
本文引述了以下文章的的內容:
完整討論串 (本文為第 3 之 29 篇):
文章代碼(AID): #1RJ7wSQd (C_and_CPP)