I hereby claim:
- I am transfusion on github.
- I am transfusion (https://keybase.io/transfusion) on keybase.
- I have a public key whose fingerprint is 57A1 E6E0 73AD 1F7A B177 1563 F5A9 9B36 38DA 0B00
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
/42/{print"SIGN"}
proof | |
# Comments like these represent my informal thoughts... | |
1 p => q Hypothesis % ok | |
2 r | s Hypothesis % ok | |
3 ~s => ~t Hypothesis % ok | |
4 ~q | s Hypothesis % ok | |
5 ~s Hypothesis % ok | |
6 ~p & r => u Hypothesis % ok | |
7 w | t Hypothesis % ok |
proof | |
# Comments like these represent my informal thoughts... | |
1 ~p => r & ~s Hypothesis % ok | |
2 t => s Hypothesis % ok | |
3 u => ~p Hypothesis % ok | |
4 ~w Hypothesis % ok | |
5 u | w Hypothesis % ok | |
# From lines d and e, u | w and ~w implies u. |
proof | |
# Comments like these represent my informal thoughts... | |
1 p | q Hypothesis % ok | |
2 q => r Hypothesis % ok | |
3 p & s => t Hypothesis % ok | |
4 ~r Hypothesis % ok | |
5 ~q => u & s Hypothesis % ok | |
# Using modus tollens on lines 2 and 4. |
#include <stdio.h> | |
#include <stdlib.h> | |
void mergeSortedLists(int a[], int b[], int c[], int sizeofa, int sizeofb){ | |
//int sizeofa = sizeof(a)/sizeof(int); | |
int indexa = 0, indexb = 0, indexc = 0; | |
//int sizeofb = sizeof(b)/sizeof(int); | |
int sizeofc = sizeofa + sizeofb; | |
printf("%d\n", sizeofc); | |
while (indexa < sizeofa && indexb < sizeofb){ | |
if(a[indexa] < b[indexb]){ |
proof | |
1 (p <=> q) <=> r Hypothesis % ok | |
2 (p <=> q) => r AndEL 1 % ok | |
3 r => (p <=> q) AndER 1 % ok | |
4 [ p Assumption % ok | |
5 [ r Assumption % ok | |
6 p <=> q ImpE 3,5 % ok | |
7 p => q AndEL 6 % ok | |
8 q ] ImpE 7,4 % ok |
$ ghci final2.hs | |
GHCi, version 7.6.3: http://www.haskell.org/ghc/ :? for help | |
Loading package ghc-prim ... linking ... done. | |
Loading package integer-gmp ... linking ... done. | |
Loading package base ... linking ... done. | |
[1 of 1] Compiling Main ( final2.hs, interpreted ) | |
Ok, modules loaded: Main. | |
*Main> :set +s | |
*Main> (showInt $ product [1..80000]) !! 476674 | |
'0' |
import Data.List | |
showInt :: Integer -> String | |
showInt number = | |
let tostr = show number | |
in let digitcount = length tostr | |
in let b = zip tostr [digitcount, digitcount-1 ..1] | |
in foldr (\x y -> | |
if snd x `mod` 3 == 0 && snd x /= digitcount | |
then " "++[fst x]++y |