214kevin

@214kevin

Joined on May 2, 2023

  • 今日當值救生員 #ifndef DUTYLIFEGUARD_H_INCLUDED #define DUTYLIFEGUARD_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void dutylifeguard(Member members[]) { int id1, id2, id3, id4, confirm; printf("Hired positions (sorted by number): \n");
     Like  Bookmark
  • 因為比起txt文字檔excel表格更容易看,我嘗試換成excel #ifndef HIREPERSON_H_INCLUDED #define HIREPERSON_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void hirePerson(Member members[]) { int id;
     Like  Bookmark
  • 追加在資料寫入文字檔前的確認 #ifndef DUTYLIFEGUARD_H_INCLUDED #define DUTYLIFEGUARD_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void dutylifeguard(Member members[]) { int id1, id2, id3, id4, confirm;
     Like  Bookmark
  • 仿照前面的代碼寫物資狀態 #ifndef TOOL_H_INCLUDED #define TOOL_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void tool(Member members[]) { int firstaidkit, lifebuoy, lifelinebag, whistle, electricfan;
     Like  Bookmark
  • 仿照前面的代碼寫泳池狀態 #ifndef POOL_H_INCLUDED #define POOL_H_INCLUDED #include <stdio.h> #include <string.h> void pool(members) { double outpH, inpH, massagepH, outppm, inppm, massageppm, outamtp, outpmtp, inamtp, inpmtp, massageamtp, massagepmtp; printf("outdoor pool pH & ppm:");
     Like  Bookmark
  • 仿照前面的代碼寫當值救生員和本日入場人數 今日當值救生員 #ifndef DUTYLIFEGUARD_H_INCLUDED #define DUTYLIFEGUARD_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void dutylifeguard(Member members[]) {
     Like  Bookmark
  • 在原有的hire person代碼上加上了寫入文字檔的功能 #ifndef HIREPERSON_H_INCLUDED #define HIREPERSON_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void hirePerson(Member members[]) { int id;
     Like  Bookmark
  • #include <stdio.h> #include <string.h> #include "functions.h" #include "showPositionsToBeHired.h" #include "showHiredPositionsByNumber.h" #include "showHiredPositionsByName.h" #include "hirePerson.h" #include "firePerson.h" #include "dutylifeguard.h" #include "admitted.h"
     Like  Bookmark
  • #ifndef HIREPERSON_H_INCLUDED #define HIREPERSON_H_INCLUDED #include <stdio.h> #include <string.h> #include "functions.h" void hirePerson(Member members[]) { int id; char name[80]; printf("Enter the number of the person you want to hire: ");
     Like  Bookmark
  • 學習記錄 pointer 電機一乙 11128271 蔡嘉泓 U-09 5/2 Hackmd 作業 電機一乙 11128271 蔡嘉泓 U-10 5/9 Hackmd作業 電機一乙 11128271 蔡嘉泓 U-11 5/16 Hackmd作業 電機一乙 11128271 蔡嘉泓 U-12 5/22 Hackmd作業 電機一乙 11128271 蔡嘉泓 U-13 5/30 Hackmd作業 期末報告專案 救生員泳池處理事項 救生員泳池處理事項
     Like  Bookmark
  • 這次的期末報告我會選擇救生員的原因是因為我之前上班的經驗,把以前上班要填的表格電子化,雖然在池邊工作用紙本會比較好,但未來防水工藝有所改變時,可能就可以用了。 這次寫的程式讓我有實用的感覺,之前學的東西都是一個一個獨立的功能,這次把學到的東西一個一個拼在一起變成一個可以實用的東西。 這次的經驗我未來的工作相當有用,未來如果我需要做類似整理資料的功能時我會更有經驗。
     Like  Bookmark
  • 原因:以前做過救生員想嘗試一下做一個電子版的工作表 要求: 顯示已聘用救生員 今日當值救生員(上午/下午) 本日入場人數(上午/下午) 泳池狀態:水溫,酸鹼值,餘氯(室外池/室內池/按摩池) 物資狀態(急救箱,救生繩袋,救生浮圈,哨子,電風扇) (之前上班的要求)
     Like  Bookmark
  • File I/O 延續上次優秀小組的招募程式,增加選項,可將結果寫入檔案,以及讀出檔案。 可使用文字檔或二進位檔,檔名及格式之處理自行訂定。 #include <stdio.h> #include <string.h> #include "functions.h" #include "showPositionsToBeHired.h" #include "showHiredPositionsByNumber.h" #include "showHiredPositionsByName.h"
     Like  Bookmark
  • AI + 專案 你現在擔任一個中階的C程式開發人員,幫協助我完成以下的工作: 使用函式指標製作以下的文字選單: Choose a function, enter 0 to finish:Show list of positions to be hired // Show numbers in a row Show list of already hired positions (Sort by number) Show list of already hired positions (Sort by name) Hire a person // Input number and name to set a position Fire a person // Input number to fire a person
     Like  Bookmark
  • Function-Pointer 1. Use qsort to sort an array with different ways: Sort from small to large Sort from large to small Odd numbers first, then even numbers; from small to large。 #include <stdio.h> #include <stdlib.h> int compareAscending(const void *a, const void *b) {
     Like  Bookmark
  • Pointer2 try to write a function to concatenate strings. void mystrcat ( char *dst, const char *src ); Test example: char a[100] = "Hello"; char b[100] = "John"; mystrcat (a, ", "); mystrcat (a, b); printf("%s", a);
     Like  Bookmark
  • Pointer Practice 1 Guess number: guess (4-digits) Correct number: answer (4-digits) Suppose the compared result is: x A y B Write a function to get x and y. And write codes to test your function. Hint: Use the following function form: void getAB (int guess, int answer, int *x, int *y);
     Like  Bookmark
  • Print Address - 1 #include <stdlib.h> int main() { int x=100; printf("x=%d at addr %p\n", x, &x); return 0; }
     Like  Bookmark