Advertisement
HabKaffee

Untitled

Apr 3rd, 2020
154
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #ifndef BUS_H
  2. #define BUS_H
  3.  
  4. typedef struct bus{
  5. char* num;
  6. char** stops;
  7. unsigned int max_stops_size;
  8. unsigned int count;
  9. }BUS;
  10.  
  11.  
  12.  
  13. typedef struct busArray{
  14. BUS* bus;
  15. unsigned int max_bus_size;
  16. unsigned int count;
  17. }BUS_ARRAY;
  18.  
  19. void declareBus(BUS* bus, char* num, char** stops, int count, int n);
  20. void nullingArrays(char* num, char** stops);
  21.  
  22. void printBus(BUS* bus, int n);
  23. int addStops(char* stopAdd, BUS* bus, int n);
  24. void changeStops(BUS* bus, char* stopChange, int number, int n);
  25. int addStopsToWay(char* stopAdd, BUS* bus, int n, int place);
  26. void changeStopsOrder(BUS* bus, int n, int num1, int num2);
  27. void deleteBusStopByNum(BUS* bus, int num, int n);
  28. void deleteBusStopByName(BUS* bus, char* name, int n);
  29.  
  30. void printBusArr(BUS_ARRAY* busArr);
  31. void addBusToBusArr(BUS_ARRAY* busArr, BUS* bus, int n);
  32.  
  33. void deleteBusFromArr(BUS_ARRAY* busArr, int number);
  34. void changeBus(BUS_ARRAY* busArr, BUS* bus, int number, int n);
  35.  
  36. #endif
Advertisement
RAW Paste Data Copied
Advertisement