﻿#include <iostream>
#include<fstream>
using namespace std;

struct node
{
	node* next;
	int val;
};

void show(node* H);
void Addtolist(node*& H, int x);

int main()
{
	node* H = NULL;
	Addtolist(H, 10);


	system("pause");
	return 0;
}


void show(node* H)
{
	cout << "H->";
	node* p = H;
	while (p != NULL)
	{
		cout << p->val << "->";
		p = p->next;
	}
	cout << "NULL" << endl;
}


void Addtolist(node*& H, int x)
{
	node* p = new node;
	p->val = x;
	p->next = H;
	H = p;
}

