Peripheral | Rate (bit/s) | Rate (byte/s) |
---|---|---|
USB 2.0 | 480 Mbit/s | 60 MB/s |
USB 3.0 | 5 Gbit/s | 625 MB/s |
Thunderbolt | 10 Gbit/s × 2 | 1.25 GB/s × 2 |
PCI Express 2.0 ×2 | 8 Gbit/s | 1 GB/s |
PCI Express 2.0 ×4 | 16 Gbit/s | 2 GB/s |
PCI Express 2.0 ×8 | 32 Gbit/s | 4 GB/s |
PCI Express 2.0 ×16 | 64 Gbit/s | 8 GB/s |
FireWire 400 | 393.216 Mbit/s | 49.152 MB/s |
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 android.app.ActivityManager; | |
import android.content.Context; | |
import android.content.pm.ConfigurationInfo; | |
public class OpenGLVersionChecker { | |
final Context context; | |
final ConfigurationInfo configurationInfo; | |
public OpenGLVersionChecker(Context context) { | |
this.context = context; |
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
(defn summer | |
[nums] | |
(if (= (count nums) 1) | |
(peek nums) | |
(+ (summer (pop nums)) (peek nums)) | |
) | |
) |
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
# Look at 2nd line, if it starts with LP then it's LG, LSN means it's Samsung | |
ioreg -lw0 | grep \"EDID\" | sed "/[^<]*</s///" | xxd -p -r | strings -6 |
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
{ | |
"auto_complete": false, | |
"binary_file_patterns": | |
[ | |
"*.jpg", | |
"*.jpeg", | |
"*.png", | |
"*.gif", | |
"*.ttf", | |
"*.tga", |
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
L1 cache reference 0.5 ns | |
Branch mispredict 5 ns | |
L2 cache reference 7 ns | |
Mutex lock/unlock 25 ns | |
Main memory reference 100 ns | |
Compress 1K bytes with Zippy 3,000 ns | |
Send 2K bytes over 1 Gbps network 20,000 ns | |
Read 1 MB sequentially from memory 250,000 ns | |
Round trip within same datacenter 500,000 ns | |
Disk seek 10,000,000 ns |
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
<?php | |
include_once "database.php"; | |
class ActiveRecord | |
{ | |
private $table = ''; | |
private $table_contents = array(); | |
private $primary_key = "id"; | |
public $ONE_TO_ONE = 1; |
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
module MyModule | |
class MyClass | |
def my_method | |
10.times { p(:small) if rand < 0.5 } | |
end | |
end | |
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
Compile-time settings (established with the "configure" script) | |
Version: freetds v0.82 | |
freetds.conf directory: /usr/local/Cellar/freetds/0.82/etc | |
MS db-lib source compatibility: yes | |
Sybase binary compatibility: no | |
Thread safety: yes | |
iconv library: yes | |
TDS version: 7.0 | |
iODBC: yes | |
unixodbc: no |
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
UIApplication sharedApplication].idleTimerDisabled = YES; |