Skip to content

Instantly share code, notes, and snippets.

View eif-courses's full-sized avatar

Marius Gžegoževskis eif-courses

View GitHub Profile
#include <iostream>
#include <fstream>
#include <string>
#include <vector>
struct Element {
std::string info;
int id, lid, rid;
};
-- Users Table (if not using ASP.NET Core Identity)
CREATE TABLE Users (
UserId INT PRIMARY KEY AUTO_INCREMENT,
Username VARCHAR(255) NOT NULL,
PasswordHash VARCHAR(255) NOT NULL, -- Adjust according to your security practices
Email VARCHAR(255) NOT NULL,
Role ENUM('Teacher', 'Student', 'Auditor') NOT NULL
);
-- Languages Table
@eif-courses
eif-courses / main.cpp
Created September 22, 2023 07:53
Task 1 assigment
#include <iostream>
#include <vector>
using namespace std;
void conversion(){
}
@eif-courses
eif-courses / main.cpp
Created September 18, 2023 07:41
synt_pi23E
#include <iostream>
#include <vector>
using namespace std;
int sum(int a, int b){
return a + b;
}
void print_sum_of_two_numbers(){
@eif-courses
eif-courses / main.cpp
Created September 18, 2023 07:40
syntax_pi23E
void print_sum_of_two_numbers(){
@eif-courses
eif-courses / env.py
Created September 12, 2023 07:35
pvzalembic
from logging.config import fileConfig
from sqlalchemy import engine_from_config
from sqlalchemy import pool
from alembic import context
# this is the Alembic Config object, which provides
# access to the values within the .ini file in use.
config = context.config
@eif-courses
eif-courses / main.py
Created May 11, 2023 07:34
duomenu_baze_template
import sqlite3
from model import Client
def connect_to_db(path: str):
return sqlite3.connect(path)
def commit_and_close_db(conn):
@eif-courses
eif-courses / main.cpp
Created April 27, 2023 07:47
composite_analogas
#include <iostream>
using namespace std;
#include <vector>
#include <map>
// Computer -> Motherboard [....], Peripherals [....]
struct Komponentas{
string pavadinimas;
map<string, string> specifikacija;
double kaina;
@eif-courses
eif-courses / simple_example.cpp
Created March 28, 2023 17:36
simple_example.cpp
// U4. Monetos LD1.cpp : This file contains the 'main' function. Program execution begins and ends there.
#include "Monetos.h"
#include "Kolekcininkas.h"
#include <string>
#include <iostream>
#include <cmath>
#include <sstream>
#include <ostream>
#include <iomanip>
#include <fstream>
@eif-courses
eif-courses / main.cpp
Created February 23, 2023 09:55
paieska_burbuliukas
#include <iostream>
#include <map>
#include <vector>
using namespace std;
const int ELEMENT_NOT_FOUND = -1;
int paieska(const vector<int> &sarasas, int skaicius) {
for (int i = 0; i < sarasas.size(); ++i) {