sh -c make-s ./llcpInt.cpp:22:29: error: no matching constructor for initialization of 'Node' Node* tmp = new Node(curr->data); NNN ./llcpInt.h:6:8: note: candidate constructor (the implicit copy constructor) not viable : no known conversion from 'int' to 'const Node' for 1st argument struct Node ./llcpInt.h:6:8: note: candidate constructor (the implicit move constructor) not viable : no known conversion from 'int' to 'Node' for 1st argument ./llcpInt.h:6:8: note: candidate constructor (the implicit default constructor) not via ble: requires arguments, but 1 was provided
#ifndef LLCP_INT_H
#define LLCP_INT_H
#include <iostream>
struct Node
{
int data;
Node *link;
};
void DelOddCopEven(Node*& headPtr);
int FindListLength(Node* headPtr);
bool IsSortedUp(Node* headPtr);
void InsertAsHead(Node*& headPtr, int value);
void InsertAsTail(Node*& headPtr, int value);
void InsertSortedUp(Node*& headPtr, int value);
bool DelFirstTargetNode(Node*& headPtr, int target);
bool DelNodeBefore1stMatch(Node*& headPtr, int target);
void ShowAll(std::ostream& outs, Node* headPtr);
void FindMinMax(Node* headPtr, int& minValue, int& maxValue);
double FindAverage(Node* headPtr);
void ListClear(Node*& headPtr, int noMsg = 0);
// prototype of DelOddCopEven of Assignment 5 Part 1
#endif



Trending now
This is a popular solution!
Step by step
Solved in 2 steps









