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
C:\Users\kealist\Documents\git\kealist\ren-c\make>mingw32-make -f makefile.boot | |
./r3-make.exe -qs ../src/tools/make-make.r OS_ID=""_"" DEBUG="asserts" \ | |
GIT_COMMIT="{unknown}" STANDARD="c" \ | |
RIGOROUS="no" WITH_FFI="no" \ | |
WITH_TCC="no" STATIC="no" \ | |
OPTIMIZE="auto" TARGET=makefile CONFIG="default-config.r" | |
/C/Users/kealist/Documents/git/kealist/ren-c/src/tools/ | |
user-config: => make object! [ | |
os-id blank! _ | |
target word! makefile |
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
// | |
// Simple listener.c program for UDP multicast | |
// | |
// Adapted from: | |
// http://ntrg.cs.tcd.ie/undergrad/4ba2/multicast/antony/example.html | |
// | |
// Changes: | |
// * Compiles for Windows as well as Linux | |
// * Takes the port and group on the command line | |
// |
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
// Test for http://stackoverflow.com/questions/8455887/stack-object-qt-signal-and-parameter-as-reference/ | |
#include <iostream> | |
#include <QCoreApplication> | |
#include <QTimer> | |
#include "param.h" | |
int main(int argc, char *argv[]) | |
{ |
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
// "Fast way" results from code by Pham Trung | |
// ( as of this revision http://stackoverflow.com/revisions/26422842/6 ) | |
// "Slow way" results from the following brute-force C++ code | |
long FSlowCore(int N, int K, int D, vector<int> & digits) { | |
if (N == 0) { | |
auto startPos = find_if(digits.begin(), digits.end(), [](int x) {return x != 0;}); | |
if (startPos != digits.begin()) | |
return 0; | |
if (search_n(startPos, digits.end(), K, D) != end(digits)) { |
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
// Test output for | |
// http://stackoverflow.com/questions/26421865/how-many-numbers-with-length-n-with-k-digits-d-consecutively/26426615 | |
when N = 0 and K = 0 and D = 6: | |
Fast way gives 0 | |
Slow way gives 0 | |
when N = 0 and K = 1 and D = 6: | |
Fast way gives 0 | |
Slow way gives 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
Rebmake [ | |
Title: "Rebol Dialected Experiment to represent CMake files" | |
;; See: | |
;; http://curecode.org/rebol3/ticket.rsp?id=2177 | |
;; http://browsenpm.org/package.json#dependencies | |
Needs: [ | |
1.0 | |
cmake 2.8 | |
] |
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
;; https://github.com/red/red/issues/941 | |
red>> foo: function [] [a: 10 b: 20 return [a b]] | |
== func [/local a b][a: 10 b: 20 return [a b]] | |
red>> reduce foo | |
;-- skip console boilerplate head code | |
eval: action/native return type: 2 | |
eval: root loop... | |
eval: fetching value of type 20 |
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
;-- Language mappings from word! to integer! for IDEone | |
;-- | |
;-- adapted from: https://ideone.com/faq | |
;-- (supported languages subsection) | |
;-- | |
;-- Capture made on 18-Mar-2014 by @HostileFork | |
[ | |
ada 7 ; gnat-4.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
WHITESPACE INTERPRETER FOR PROGRAM: | |
--- | |
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
// | |
// Proxy/facade pattern idea. | |
// See http://codereview.stackexchange.com/questions/33713/ | |
// | |
#include <iostream> | |
#include <vector> | |
#include <memory> | |
#include <cstdlib> |
NewerOlder