记录c++里引用数据结构的经典写法。
View test.skema
| [{"name":"Bears","color":"Blue","position":{"x":177,"y":85},"modelclass":"Bear","increment":false,"timestamp":false,"softdelete":false,"column":[{"colid":"c217","name":"id","type":"increments","length":"0","order":0,"defaultvalue":"","enumvalue":""},{"colid":"c218","name":"name","type":"string","length":"200","order":1,"defaultvalue":"","enumvalue":""},{"colid":"c219","name":"danger_level","type":"string","length":"200","order":2,"defaultvalue":"","enumvalue":""}],"relation":[{"extramethods":"","foreignkeys":"","name":"fish","relatedmodel":"Fish","relationtype":"hasOne","usenamespace":""},{"extramethods":"","foreignkeys":"","name":"trees","relatedmodel":"Trees","relationtype":"hasMany","usenamespace":""},{"extramethods":"","foreignkeys":"bear_id, picnic_id","name":"picnics","relatedmodel":"Picnics","relationtype":"belongsToMany","usenamespace":""}],"seeding":[]},{"name":"Fish","color":"Yellow","position":{"x":1063,"y":14},"modelclass":"Fish","increment":false,"timestamp":false,"softdelete":false,"column":[{"c |
View gist:3ba2c5f05ae84fd066a8a7cde96e4dca
| 📗 | |
| Protocol defining basic JSON functionality | |
| 📗 | |
| 🐊 🏗🐚T⚪🍆 🍇 | |
| 📗 | |
| Turn a 🏗 into a string | |
| 📗 | |
| ❗🚧 ➡ 🔡 | |
| 📗 |
View specs.txt
| ##### release ########################### | |
| Distributor ID: Ubuntu | |
| Description: Ubuntu 18.04.1 LTS | |
| Release: 18.04 | |
| Codename: bionic | |
| ##### kernel ############################ | |
| Linux 4.15.0-33-generic #36-Ubuntu SMP Wed Aug 15 16:00:05 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux |
View animations.txt
| 0 = ragdoll | |
| 1 = idle_subtle | |
| 2 = idle_angry | |
| 3 = LineIdle01 | |
| 4 = LineIdle02 | |
| 5 = LineIdle03 | |
| 6 = LineIdle04 | |
| 7 = Crouch_idleD | |
| 8 = layer_crouch_walk_no_weapon | |
| 9 = layer_crouch_run_no_weapon |
View MPIExamples.cpp
| #include "stdafx.h"; | |
| #include <iostream> | |
| #include <mpi.h> | |
| #include <ctime> | |
| #include <vector> | |
| #include <stdio.h> | |
| #include <string> | |
| /* | |
| 4. Proces 0 kreira matricu reda n i šalje i-om procesu po dve kvazidijagonale matrice, obe | |
| na udaljenosti i od sporedne dijagonale. Proces i kreira svoju matricu tako što smešta |
View swiftCode.html
| <style>pre { background-color: #1a1a1a; border: 0px solid #ccc; padding: 0px; margin-bottom: 0px; } pre code { display: block; color: #a9bcbc; line-height: 1.4em; font-size: 0.95em; white-space: pre; } pre code .keyword { color: #e73289; } pre code .type { color: #8281ca; } pre code .call { color: #348fe5; } pre code .property { color: #21ab9d; } pre code .number { color: #db6f57; } pre code .string { color: #fa641e; } pre code .comment { color: #6b8a94; } pre code .dotAccess { color: #92b300; } .box { padding: 20px; margin: 0 auto; display: block; border-radius: 8px; background-color: #1a1a1a; border: 0px solid #ccc; } </style> | |
| <!--Generate code at: https://splash.rambo.codes/ and then COPY HTML--> | |
| <section class="box"><pre><code><!--Paste the code with the <span> tags after this--> | |
| <!--This should be on the same line as the last line of the swift code--></code></pre></section> |
View dagopy.py
| from functools import partial, wraps | |
| pipetypes = {} | |
| def pipetype(func): | |
| pipetypes[func.__name__] = func | |
| @wraps(func) | |
| def wrapper(*args, **kwargs): |
View readme.txt
| Play this game by pasting the script in http://www.puzzlescript.net/editor.html |
View perdevicethreadpool.py
| from contextlib import contextmanager | |
| import pyudev | |
| from select import select | |
| import threading | |
| import select, os, queue, socket | |
| class PollableQueue(queue.Queue): | |
| def __init__(self): | |
| super().__init__() | |
| # Create a pair of connected sockets |
NewerOlder