Advertisement
zodiak1

Untitled

Feb 9th, 2022
171
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.30 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <conio.h>
  3.  
  4. struct list
  5. {
  6.    char v;
  7.    list *n;
  8. };
  9.  
  10. int main()
  11. {
  12.    list *a = new list;
  13.    
  14.    //Верхняя схема
  15.    list *p = new list {1, new list};
  16.    p->n = new list { 2, new list };
  17.    p->n->n = new list { 3, NULL };
  18.  
  19.    return 0 * _getch();
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement