Skip to content

Instantly share code, notes, and snippets.

View Soulstorm50's full-sized avatar

Soul Soulstorm50

View GitHub Profile
@Soulstorm50
Soulstorm50 / Time.cpp
Created July 12, 2016 20:28
class Time
#include"Time.h"
void Time::SetHour(uint hour)
{
if (hour <24)
this->hour = hour;
}
void Time::SetMin(uint min)
{
if (min < 60)
#include"Vector.h"
Vector::Vector()
{
count = 0;
capacity = 10;
arr = new int[capacity];
}
#include"Group.h"
Group::Group()
{
group_size = 0;
group_name = nullptr;
group_spec = nullptr;
course_num = nullptr;
students = nullptr;
}
#include "Student.h"
#include"Dob.h"
#include"Adress.h"
#include<string.h>
Student::Student(char* phone,char*name,char*secondname,char*lastname)
{
SetPhone(phone);
SetName(name);
@Soulstorm50
Soulstorm50 / SinglyLinkedList.cpp
Created August 13, 2016 17:19
SinglyLinkedList
#include"SinglyLinkedList.h"
using namespace std;
SingleLinkedList::SingleLinkedList()
{
head = tail = nullptr;
count = 0;
}
SingleLinkedList::SingleLinkedList(SingleLinkedList& origin)
@Soulstorm50
Soulstorm50 / DoubleLinkedList.cpp
Created August 13, 2016 17:24
DoubleLinkedList
#include"DoubleLinkedList.h"
using namespace std;
DoubleLinkedList::DoubleLinkedList()
{
head = tail = nullptr;
count = 0;
}
void DoubleLinkedList::ClearList()
#include <iostream>
#include <ctime>
using namespace std;
class Stack
{
int stack_size;
char *mass;
int top;
void Resize()
@Soulstorm50
Soulstorm50 / Deque.cpp
Created August 13, 2016 17:52
Deque.cpp
#include<iostream>
#include"DoubleLinkedList.h"
using namespace std;
class Deque
{
DoubleLinkedList d;
uint counter = 0;
public:
Deque()
{
@Soulstorm50
Soulstorm50 / MainDequeDoubleList.cpp
Created August 13, 2016 17:53
MainDequeDoubleList.cpp
#include<iostream>
#include"Deque.cpp"
#include"DoubleLinkedList.h"
using namespace std;
void main()
{
DoubleLinkedList d;
@Soulstorm50
Soulstorm50 / PoliceViolationTree.cpp
Created August 13, 2016 18:01
PoliceViolationTree
#include<iostream>
using namespace std;
typedef unsigned int uint;
class PoliceData;
class Node;
class Violation
{
struct Elem