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
| /* This is free and unencumbered software released into the public domain. | |
| * Anyone is free to copy, modify, publish, use, compile, sell, or | |
| * distribute this software, either in source code form or as a compiled | |
| * binary, for any purpose, commercial or non-commercial, and by any | |
| * means. | |
| * In jurisdictions that recognize copyright laws, the author or authors | |
| * of this software dedicate any and all copyright interest in the | |
| * software to the public domain. We make this dedication for the benefit | |
| * of the public at large and to the detriment of our heirs and | |
| * successors. We intend this dedication to be an overt act of |
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 <libexplain/popen.h> | |
| #include <stdio.h> | |
| #include <stdarg.h> | |
| bool | |
| run_shell(char* out_buffer, const size_t out_buffer_size, const char* command_fmt, ...) { | |
| va_list va; | |
| va_start(va, command_fmt); | |
| char command[strlen(command_fmt) + 256]; |
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
| /* Нода дека */ | |
| typedef struct DNode { | |
| int num; | |
| int group; | |
| char FIO[64]; | |
| struct DNode *left; // Указатель на элемент слева | |
| struct DNode *right; // Указатель на элемент справа | |
| } DNode; | |
| typedef struct { |
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
| fn main() { | |
| use std::time::SystemTime; | |
| let mut timers = Vec::with_capacity(10); | |
| let mut hash = 0; | |
| for _ in 0..10 { | |
| // Starting timer | |
| let before_time = SystemTime::now(); |
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
| #!/bin/bash | |
| # Description: Prints how much time one could have fun with friends or make out with {girl,boy}friend, but compiled h{is,er} Gentoo | |
| # Author: Mike Lubints (aka mersinvald) 2016 | |
| # | |
| # Dependencies: | |
| # bash | |
| # bc | |
| # genlop | |
| # | |
| # Note: runs from root (or with portage rights) |
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
| #![feature(inclusive_range_syntax)] | |
| macro_rules! new_model { | |
| ($struct_name:ident { | |
| $( $arg:ident : $arg_type:ty ),* | |
| }, table: $table:expr) => ( | |
| #[derive(Clone, Debug)] | |
| pub struct $struct_name { | |
| pub id: i32, | |
| $ ( |
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
| hms_api v0.1.0 (file:///home/mike/dev/rust/Innopolis/hms_api) | |
| ├── chrono v0.2.25 | |
| │ ├── num v0.1.36 | |
| │ │ ├── num-bigint v0.1.35 | |
| │ │ │ ├── num-integer v0.1.32 | |
| │ │ │ │ └── num-traits v0.1.36 | |
| │ │ │ ├── num-traits v0.1.36 (*) | |
| │ │ │ ├── rand v0.3.14 | |
| │ │ │ │ └── libc v0.2.17 | |
| │ │ │ └── rustc-serialize v0.3.19 |
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
| traitobject v0.0.3 | |
| ├── error v0.1.9 | |
| │ └── iron v0.4.0 | |
| │ ├── bodyparser v0.4.1 | |
| │ │ ├── params v0.5.0 | |
| │ │ │ └── hms_api v0.1.0 (file:///home/mike/dev/rust/Innopolis/hms_api) | |
| │ │ └── urlencoded v0.4.1 | |
| │ │ └── params v0.5.0 (*) | |
| │ ├── hms_api v0.1.0 (file:///home/mike/dev/rust/Innopolis/hms_api) (*) | |
| │ ├── oven v0.4.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
| class ComputationQueue { | |
| Queue<Runnable> tasks = new Queue<>(); | |
| public void push_task(Runnable task) { | |
| tasks.push(task); | |
| } | |
| public void execute() { | |
| for(Task task: tasks) { | |
| task.run(); |
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
| use hyper::{Request, Response}; | |
| use hyper::server::NewService; | |
| use hyper::server::Service; | |
| use hyper; | |
| use futures::Future; | |
| use futures::future; | |
| use std::collections::BTreeMap; | |
| use std::borrow::Cow; | |
| use std::rc::Rc; | |
| use std::sync::Arc; |
OlderNewer