4 questions
#include<stdio.h>void MaxAndMin(int * arr,int size,int **mxptr,int **mnptr){ int * max,* min; int i; *max=*min=arr[0]; for(i=0;i<size;i++) { if(*max<arr[i]) *max=arr[i]; if(*min>arr[...
#include<stdio.h>void rotate(int(*ptr)[4]){ int i,j; int temp[4][4]; for(i=0;i<4;i++) { for(j=0;j<4;j++) { temp[i][j]=ptr[3-j][i]; } } for(i=0;i<4;i++) { for(j=0;j<4;j++) { pt...
When searching in a linked list, you search by creating a ListNode *p variable as shown below.void print_list(ListNode *head){ for(ListNode *p = head ; p != NULL ; p = p->link) printf(%d->,p-&g...
class account{private: int accid; int balance; char *name;public: account(int id, int money, const char* a) :accid(id), balance(money) { name = new char[strlen(a) + 1]; strcpy(name, a); } account(c...
© 2024 OneMinuteCode. All rights reserved.