This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import re | |
| from collections import namedtuple | |
| Eszleles = namedtuple('Eszleles', ['nap', 'amator', 'uzenet']) | |
| eszlelesek = [] # ^ ez olyan, mint a class csak nem kell initelni | |
| # 1. feladat | |
| with open('veetel.txt') as be: # becsukja magatol igy a txt-t utana | |
| sorok = be.read().splitlines() # ujsor karakter nelkul |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <sstream> | |
| #include <string> | |
| #include <fstream> | |
| #include <vector> | |
| #include <set> | |
| #include <map> | |
| using namespace std; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <vector> | |
| #include <algorithm> | |
| #include <string> | |
| #include <cstdlib> | |
| #include <ctime> | |
| #include <functional> | |
| #include <random> | |
| #include <chrono> | |
| #include <thread> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1530 1600 | |
| 1555 1645 | |
| 1600 1630 | |
| 1635 1715 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| import sympy | |
| import re | |
| def build_side(side): | |
| r_molec = re.compile(r"([0-9]*)([A-Z][a-z]*[0-9]*)*") | |
| r_item = re.compile(r"(?P<elem>[a-z]+)(?P<num>[0-9]*)", re.IGNORECASE) | |
| elems = set() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "creature.h" | |
| #include <iostream> | |
| using namespace std; | |
| /* Default Constructor */ | |
| Creature::Creature() | |
| { | |
| Name = "Default"; | |
| Health = 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| PassEvent = Struct.new(:reg_id, :time_s) # rendszam, ido mp-be | |
| def text_time_to_secs(text) | |
| parts = text.split(':') # feldarabolja egy tombbe a kettospontok menten | |
| parts[0].to_i * 3600 + parts[1].to_i * 60 + parts[2].to_i | |
| # to_i: string -> integer kovertal, es szokasos szorzasok mp-be | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'guillotine' | |
| require 'redis' | |
| module Katana | |
| class App < Guillotine::App | |
| # use redis adapter with redistogo | |
| REDIS = Redis.new(:host => ENV["OPENSHIFT_REDIS_HOST"], :port => ENV["OPENSHIFT_REDIS_PORT"], :password => ENV["REDIS_PASSWORD"]) | |
| adapter = Guillotine::Adapters::RedisAdapter.new REDIS | |
| set :service => Guillotine::Service.new(adapter, :strip_query => false, | |
| :strip_anchor => false) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| uri = URI.parse(ENV["REDISTOGO_URL"]) | |
| REDIS = Redis.new(:host => uri.host, :port => uri.port, :password => uri.password) | |
| # HELYETT! | |
| REDIS = Redis.new(:host => ENV["OPENSHIFT_REDIS_DB_HOST"], :port => ENV["OPENSHIFT_REDIS_DB_PORT"]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 3.14159265358979323846264338327950288419716939937510582097494459230781640628620899862803482534211706798214808651328230664709384460955058223172535940812848111745028410270193852110555964462294895493038196442881097566593344612847564823378678316527120190914564856692346034861045432664821339360726024914127372458700660631558817488152092096282925409171536436789259036001133053054882046652138414695194151160943305727036575959195309218611738193261179310511854807446237996274956735188575272489122793818301194912983367336244065664308602139494639522473719070217986094370277053921717629317675238467481846766940513200056812714526356082778577134275778960917363717872146844090122495343014654958537105079227968925892354201995611212902196086403441815981362977477130996051870721134999999837297804995105973173281609631859502445945534690830264252230825334468503526193118817101000313783875288658753320838142061717766914730359825349042875546873115956286388235378759375195778185778053217122680661300192787661119590921642019893809525720106548586327 |