Skip to content

Instantly share code, notes, and snippets.

View NightBrownie's full-sized avatar

Nikita Kliushnikov NightBrownie

View GitHub Profile
@NightBrownie
NightBrownie / lab_4_1.cpp
Created April 27, 2011 17:13
Programming_lab_2_sem_4.1_var_9
// Lab_4_1_var-9.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <malloc.h>
#include <conio.h>
#define max_length 50
const char priority[4][2] = {{'+','1'},{'-','1'},{'*','2'},{'/','2'}}; //массив соответствия приоритета операциям
// Programming_4_2_lab_var_9.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <stdio.h>
#include <conio.h>
#include <stdlib.h>
#include <malloc.h>
#define NOS 32
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Lab_3_inisp
{
class ListItem<T>
{
public ListItem<T> Next
1. возраст
2. получаю 1 высшее | 2+ высшее
3. холост | есть семья
4. не работаю | работаю 1/2 ставки | полный раб. день
if работаю {
5. колво часов работы в день
6. зарплата
< 3M | 3M - 6M | 6M - 10M | 10M+
;07) Шар и сопряженную пирамиду с треугольником в основании.
.model small
.stack 1000h
.data
saveMode db ?
color db 30
x dw ?
y dw ?
x1 dw ?
x2 dw ?
@NightBrownie
NightBrownie / gist:1423114
Created December 2, 2011 12:44
План классов для игры
Классы для самой игры:
1)Осноной класс GameObject
А)Поле IsAllive
2)Класс составной части корабля ShipPart
А)Наследование от GameObject
Б)Наследование от DrawableObject
В)Клетка поля, на которой стоит данная часть корабля
3)Класс корабля Ship
А)Коллекция составных частей корабля
Б)Кол-во составных частей
#include "stdafx.h"
#include "Discovery.h"
Discovery::Discovery(char* addr, int port, DiscoveryListener* l) {
listener = l;
int n;
unsigned int length;
struct sockaddr_in server, from;
struct hostent *hp;
char buffer[256];
@NightBrownie
NightBrownie / client.cpp
Created December 24, 2011 11:42
client app
#include "stdafx.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/types.h>
#include <pthread.h>
#include "Client.h"
#include <iostream>
using namespace std;
#include "stdafx.h"
#include "Server.h"
#include <conio.h>
#include <iostream>
using namespace std;
Server* s;
class Listener : public ServerListener {
public:
/*#include "stdafx.h"
#include "Server.h"
#include <conio.h>
#include <iostream>
using namespace std;
Server* s;
class Listener : public ServerListener {
public: