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
N = 1024 Accel: 0.05265 FFTW: 0.026213 | |
N = 2048 Accel: 0.042565 FFTW: 0.049334 | |
N = 4096 Accel: 0.049206 FFTW: 0.082782 | |
N = 8192 Accel: 0.118918 FFTW: 0.173506 | |
N = 16384 Accel: 0.200201 FFTW: 0.371488 | |
N = 32768 Accel: 0.356826 FFTW: 1.01589 | |
N = 65536 Accel: 0.844955 FFTW: 1.79316 | |
N = 131072 Accel: 1.95759 FFTW: 3.99565 | |
N = 262144 Accel: 4.34179 FFTW: 9.87287 | |
N = 524288 Accel: 9.31858 FFTW: 19.6675 |
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 React, { Component } from 'react'; | |
import {TextInput, TouchableWithoutFeedback, StyleSheet} from 'react-native'; | |
const Platform = require('Platform'); | |
const requireNativeComponent = require('requireNativeComponent'); | |
const emptyFunction = require('fbjs/lib/emptyFunction'); | |
if (Platform.OS === 'android') { | |
var AndroidTextInput = requireNativeComponent('AndroidTextInput', null); | |
} else if (Platform.OS === 'ios') { | |
var RCTTextView = requireNativeComponent('RCTTextView', null); |
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 UIKit | |
import Foundation | |
import XCPlayground | |
XCPSetExecutionShouldContinueIndefinitely() | |
class RemoteAPI { | |
func getData(completionHandler: ((NSArray!, NSError!) -> Void)!) -> Void { | |
let url: NSURL = NSURL(string: "http://itunes.apple.com/search?term=Turistforeningen&media=software") | |
let ses = NSURLSession.sharedSession() |
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
# Sample implementation of quicksort and mergesort in ruby | |
# Both algorithm sort in O(n * lg(n)) time | |
# Quicksort works inplace, where mergesort works in a new array | |
def quicksort(array, from=0, to=nil) | |
if to == nil | |
# Sort the whole array, by default | |
to = array.count - 1 | |
end |