- Examine The Following Code Fragment And Show The Results Cout List Info 10 Endl Cout A Info 10 Endl C 1 (213.53 KiB) Viewed 27 times
Examine the following code fragment and show the results. cout << list->info+ 10 << endl; cout << A->info+ 10 << endl; c
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
Examine the following code fragment and show the results. cout << list->info+ 10 << endl; cout << A->info+ 10 << endl; c
Examine the following code fragment and show the results. cout << list->info+ 10 << endl; cout << A->info+ 10 << endl; cout << A->info+ B->link->info << endl; cout << list->link->link->info << endl; A = A->link; B = B->link; cout << A->info + B->info << endl; b) Tunjukkan ilustrasi senarai berpaut untuk menambah 90 sebelum B. Show the linked list illustration to add 90 before B. (2 markah/marks) (2 markah/marks) c) Bina satu fungsi untuk mengembalikan nod penunjuk B dalam senarai berpaut. Gunakan nama fungsi sebagai node* assignPointer (nod list, int val), dengan list ialah permulaan atau kepala senarai berpaut dan val ialah nilai penunjuk B. Build a function to return the node the pointer B in the linked list. Use the function name as node assignPointer (node *list, int val), where list is the start or head of the linked list and val is the value of the pointer B. (6 markah/marks)