<commit_before>#include<iostream>
using namespace std;

class N_LIST
{
public:
  int data;
  N_LIST *ptr;
};

class L_LIST
{
private:
  N_LIST *head;

public:
  L_LIST()
  {
    head = NULL;
  }

  void insert_front();
  int delete_front();
  void display();

  ~L_LIST()
  {
    delete head;
  }

};

void L_LIST :: insert_front()
{
  N_LIST *newnode;
  int item;
  newnode = new N_LIST;
  cout << "\tEnter the element to be inserted: ";
  cin >> item;
  newnode->data = item;
  newnode->ptr = head;
  head = newnode;
}

int L_LIST :: delete_front()
{
  N_LIST *temp;
  int item;
  if (head == NULL)
    {
      cout << "\tList is empty." << endl;
      return 1;
    }
  temp = head;
  cout << "\tDeleted element is " << temp->data << endl;
  item = temp->data;
  head = head->ptr;
  delete(temp);
  return item;
}

void L_LIST :: display()
{
  N_LIST *temp;
  temp = head;
  if( head == NULL )
    {
      cout << "List is empty." << endl;
      return;
    }
  cout << "\n\tContents of the list..." << endl;
  while (temp != NULL)
    {
      cout << temp->data << "-->";
      temp = temp->ptr;
    }
  cout << "NULL" << endl;
}

void main()
{
  L_LIST LL;
  int choice, rpt;
  while(rpt)
    {
      cout << "\n\n\t1.Insert at front." << endl;
      cout << "\t2. Delete from front." << endl;
      cout << "\t3. Display." << endl;
      cout << "\t4. Exit." << endl;
      cout << "\n\tEnter your choice: ";
      cin >> choice;
      switch(choice)
	{
	case 1:
	  LL.insert_front();
	  break;
	case 2:
	  LL.delete_front();
	  break
	case 3:
	  LL.display();
	  break;
	case 4:
	  return;
	}

      cout << "\tPress 1 to continue or 0 to exit." << endl;
      cin >> rpt;
    }
}<commit_msg>Datshans typo fixed Prog8<commit_after>#include <iostream>
using namespace std;

class N_LIST
{
public:
  int data;
  N_LIST *ptr;
};

class L_LIST
{
private:
  N_LIST *head;

public:
  L_LIST()
  {
    head = NULL;
  }

  void insert_front();
  int delete_front();
  void display();

  ~L_LIST()
  {
    delete head;
  }

};

void L_LIST :: insert_front()
{
  N_LIST *newnode;
  int item;
  newnode = new N_LIST;
  cout << "\tEnter the element to be inserted: ";
  cin >> item;
  newnode->data = item;
  newnode->ptr = head;
  head = newnode;
}

int L_LIST :: delete_front()
{
  N_LIST *temp;
  int item;
  if (head == NULL)
    {
      cout << "\tList is empty." << endl;
      return 1;
    }
  temp = head;
  cout << "\tDeleted element is " << temp->data << endl;
  item = temp->data;
  head = head->ptr;
  delete(temp);
  return item;
}

void L_LIST :: display()
{
  N_LIST *temp;
  temp = head;
  if( head == NULL )
    {
      cout << "List is empty." << endl;
      return;
    }
  cout << "\n\tContents of the list..." << endl;
  while (temp != NULL)
    {
      cout << temp->data << "-->";
      temp = temp->ptr;
    }
  cout << "NULL" << endl;
}

int main()
{
  L_LIST LL;
  int choice, rpt=1;
  while(rpt)
    {
      cout << "\n\n\t1.Insert at front." << endl;
      cout << "\t2. Delete from front." << endl;
      cout << "\t3. Display." << endl;
      cout << "\t4. Exit." << endl;
      cout << "\n\tEnter your choice: ";
      cin >> choice;
      switch(choice)
	{
	case 1:
	  LL.insert_front();
	  break;
	case 2:
	  LL.delete_front();
	  break;
	case 3:
	  LL.display();
	  break;
	case 4:
	  return 1;
	}

      cout << "\tPress 1 to continue or 0 to exit." << endl;
      cin >> rpt;
    }
    return 1;
}
{'fraction_non_alphanumeric': 0.16943715368912218, 'fraction_numerical': 0.00758238553514144, 'mean_word_length': 2.158379373848987, 'pattern_counts': {'":': 0, '<': 105, '<?xml version=': 0, '>': 33, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6630816', 'n_tokens_mistral': 1348, 'n_tokens_neox': 1318, 'n_words': 365}