Start a new Kumite
AllAgda (Beta)BF (Beta)CCFML (Beta)ClojureCOBOL (Beta)CoffeeScriptCommonLisp (Beta)CoqC++CrystalC#D (Beta)DartElixirElm (Beta)Erlang (Beta)Factor (Beta)Forth (Beta)Fortran (Beta)F#GoGroovyHaskellHaxe (Beta)Idris (Beta)JavaJavaScriptJulia (Beta)Kotlinλ Calculus (Beta)LeanLuaNASMNim (Beta)Objective-C (Beta)OCaml (Beta)Pascal (Beta)Perl (Beta)PHPPowerShell (Beta)Prolog (Beta)PureScript (Beta)PythonR (Beta)RacketRaku (Beta)Reason (Beta)RISC-V (Beta)RubyRustScalaShellSolidity (Beta)SQLSwiftTypeScriptVB (Beta)
Show only mine

Kumite (ko͞omiˌtā) is the practice of taking techniques learned from Kata and applying them through the act of freestyle sparring.

You can create a new kumite by providing some initial code and optionally some test cases. From there other warriors can spar with you, by enhancing, refactoring and translating your code. There is no limit to how many warriors you can spar with.

A great use for kumite is to begin an idea for a kata as one. You can collaborate with other code warriors until you have it right, then you can convert it to a kata.

Ad
Ad
Code
Diff
  • rps=(a,b)=>a==b?'Draw!':`Player ${2-/sp|rr|ks/.test(a+b)} won!`
    • const rps=(p,z)=>p==z?'Draw!':`Player ${1+/sr|ps|rp/.test(p[0]+z[0])} won!`;
    • rps=(a,b)=>a==b?'Draw!':`Player ${2-/sp|rr|ks/.test(a+b)} won!`
Fundamentals
Strings

lets obfuscate poorly, just gotta dig a bit to find it

Code
Diff
  • let _4x5c408c18="73af22ddab9cb4";const _6x78f515ef="ec57ccc63165a2";const _0x5334e741=()=>"f38199e2edcf88";var _5x1da78b14="61f49175bf352d";const _8x22e9a61e=()=>"fcbeee09383628";let _9x06bbd677="64ed0c0c76a765";const _8xdfd86978="366769690cdd28";function _1xe9b516d0(){return "114352a3c70d30"};var _2x1a6abe0d="5703f8856e1f6a";var _0xf9284b77="a74c3160b26e3a";const _9xa1e6814f=()=>"333a314fcdd3ac";let _5x2722b9e4="44f6dd823fddb0";function _3x65f150d9(){return "4e6d417f693359"};const _2x95ae13db="d07f7f4d47aa18";const _7x117cb966=()=>"d11ad5cacaead0";var _4x7a51b9a4="eccee5f0bced7f";const _3x42e4ad3c=()=>"0752662f54d670";let _2xefc662ec="7cde3c89efdf57";const _2xdc97b525=()=>"3ab201ac5b7565";var _5x5a3ef867="055b4c2c00d9f8";const _2xace2125e=()=>"da2e7577e6415b";var _1x57aed60d="02d0d64c828040";function _1xc76ae9e8(){return "c93f53eceab3f0"};var _8x465bdabc="4f16b6cc9afc30";let _5x38085754="00741c56afd6d8";let _0x041ebfb2="51a4d02a37b044";const _7xdb747709=()=>"41e4065be801fa";var _2x1ff5c00b="d12fb2a678aab6";const _1xd8b553a5=()=>"813c9532b6286f";let _3xdcb1d0da="f3148604aec0dd";const _4xb2e4a581="12809401fde57d";const _4x0e4dfa7e=()=>"515c50f1121f3a";let _9xd61a558f="9db1be0bc0b8b4";reverseStr=s=>[...s].reverse().join``;function _9xb190026c(){return "bd5815bdad126a"};const _4x1b7c962a="f54f53ebf55c5f";function _8x3b46f7af(){return "b28c45d293cfd3"};let _9xbc152fef="8b1a150d72b441";function _1x87bd9902(){return "6c3470c57eb9b4"};let _8x6408511b="09749b3b666ddf";const _2x51837b6a="39bbebfd4f59ef";let _9x6b8f9798="b3071ace5f112f";const _6x82989519=()=>"4b73dab8f2c3d2";const _4x3bbb09d7="64c32024845faa";function _2x66907531(){return "5a66fc3a38cf48"};var _6xc7d7fc90="3b56773f53482a";var _5x34cb55a5="673a3ed22e58ea";function _9x8e1846d1(){return "14dedae52aeb36"};let _4x1b7615a1="a8de40853b6b80";var _0x190b2d9e="44c32724c7762c";var _2xe2134a36="93e3c7b39d401d";function _2xec4b7395(){return "2ea5745c103582"};let _1x63b3b95f="d533684f6299bf";function _2x04692cda(){return "7a4fd8458ebd89"};const _5x46c020ab="32bf81a3bbe9f8";let _1x03abdb70="7fbcfaac07140e";const _3x092cef93=()=>"e891ff249db6dc";var _2xcada4ded="e6b7588c64c280";var _2xefc990cc="d7d15791dfdbb8";const _3x86b8aca5=()=>"1a5cfe8b1ee2ac";var _1xf5715021="83cc733f71d0f9";const _6x38540419=()=>"ddfed66236c34a";const _1x7cf98a6b="07001608a881a0";const _2x2215b06a=()=>"5ce8ad6c6343c8";var _9xf282ec48="7ff71192fe4a79";function _2x57e16f5a(){return "46de17e4071a33"};var _9xa6a835dd="58ef25b420e26c";
    • \u0072\u0065\u0076\u0065\u0072\u0073\u0065\u0053\u0074\u0072=\u0073=>[...\u0073].\u0072\u0065\u0076\u0065\u0072\u0073\u0065().\u006a\u006f\u0069\u006e``
    • let _4x5c408c18="73af22ddab9cb4";const _6x78f515ef="ec57ccc63165a2";const _0x5334e741=()=>"f38199e2edcf88";var _5x1da78b14="61f49175bf352d";const _8x22e9a61e=()=>"fcbeee09383628";let _9x06bbd677="64ed0c0c76a765";const _8xdfd86978="366769690cdd28";function _1xe9b516d0(){return "114352a3c70d30"};var _2x1a6abe0d="5703f8856e1f6a";var _0xf9284b77="a74c3160b26e3a";const _9xa1e6814f=()=>"333a314fcdd3ac";let _5x2722b9e4="44f6dd823fddb0";function _3x65f150d9(){return "4e6d417f693359"};const _2x95ae13db="d07f7f4d47aa18";const _7x117cb966=()=>"d11ad5cacaead0";var _4x7a51b9a4="eccee5f0bced7f";const _3x42e4ad3c=()=>"0752662f54d670";let _2xefc662ec="7cde3c89efdf57";const _2xdc97b525=()=>"3ab201ac5b7565";var _5x5a3ef867="055b4c2c00d9f8";const _2xace2125e=()=>"da2e7577e6415b";var _1x57aed60d="02d0d64c828040";function _1xc76ae9e8(){return "c93f53eceab3f0"};var _8x465bdabc="4f16b6cc9afc30";let _5x38085754="00741c56afd6d8";let _0x041ebfb2="51a4d02a37b044";const _7xdb747709=()=>"41e4065be801fa";var _2x1ff5c00b="d12fb2a678aab6";const _1xd8b553a5=()=>"813c9532b6286f";let _3xdcb1d0da="f3148604aec0dd";const _4xb2e4a581="12809401fde57d";const _4x0e4dfa7e=()=>"515c50f1121f3a";let _9xd61a558f="9db1be0bc0b8b4";reverseStr=s=>[...s].reverse().join``;function _9xb190026c(){return "bd5815bdad126a"};const _4x1b7c962a="f54f53ebf55c5f";function _8x3b46f7af(){return "b28c45d293cfd3"};let _9xbc152fef="8b1a150d72b441";function _1x87bd9902(){return "6c3470c57eb9b4"};let _8x6408511b="09749b3b666ddf";const _2x51837b6a="39bbebfd4f59ef";let _9x6b8f9798="b3071ace5f112f";const _6x82989519=()=>"4b73dab8f2c3d2";const _4x3bbb09d7="64c32024845faa";function _2x66907531(){return "5a66fc3a38cf48"};var _6xc7d7fc90="3b56773f53482a";var _5x34cb55a5="673a3ed22e58ea";function _9x8e1846d1(){return "14dedae52aeb36"};let _4x1b7615a1="a8de40853b6b80";var _0x190b2d9e="44c32724c7762c";var _2xe2134a36="93e3c7b39d401d";function _2xec4b7395(){return "2ea5745c103582"};let _1x63b3b95f="d533684f6299bf";function _2x04692cda(){return "7a4fd8458ebd89"};const _5x46c020ab="32bf81a3bbe9f8";let _1x03abdb70="7fbcfaac07140e";const _3x092cef93=()=>"e891ff249db6dc";var _2xcada4ded="e6b7588c64c280";var _2xefc990cc="d7d15791dfdbb8";const _3x86b8aca5=()=>"1a5cfe8b1ee2ac";var _1xf5715021="83cc733f71d0f9";const _6x38540419=()=>"ddfed66236c34a";const _1x7cf98a6b="07001608a881a0";const _2x2215b06a=()=>"5ce8ad6c6343c8";var _9xf282ec48="7ff71192fe4a79";function _2x57e16f5a(){return "46de17e4071a33"};var _9xa6a835dd="58ef25b420e26c";
Strings

Given two UTF-8 strings, calculate the sum of each string's characters and return true if they match.

are_utf8_sums_equal("Anna", "Nana") == true
  "Anna" == 65 + 110 + 110 + 97 == 382
  "Nana" == 78 + 97 + 110 + 97  == 382

are_utf8_sums_equal("Sebastian", "Patricia") == false
  "Sebastian" == 83 + 101 + 98 + 97 + 115 + 116 + 105 + 97 + 110 == 922
  "Patricia"  == 80 + 97 + 116 + 114 + 105 + 99 + 105 + 97       == 813

are_utf8_sums_equal("わたしのごく", "わたしはごぎ") == true
  "わたしのごく" == 12431 + 12383 + 12375 + 12398 + 12372 + 12367 == 74326
  "わたしはごぎ" == 12431 + 12383 + 12375 + 12399 + 12372 + 12366 == 74326
Code
Diff
  • fn are_utf8_sums_equal(a: &str, b: &str) -> bool {
    	utf8_sum(a) == utf8_sum(b)
    }
    
    fn utf8_sum(string: &str) -> u32 {
    	string.chars().map(u32::from).sum()
    }
    
    • fn verify_sum(name_one: &str, name_two: &str) -> bool {
    • sum(name_one) == sum(name_two)
    • fn are_utf8_sums_equal(a: &str, b: &str) -> bool {
    • utf8_sum(a) == utf8_sum(b)
    • }
    • fn sum(name: &str) -> u32 {
    • name.chars()
    • .filter(|ch| ch.is_ascii_alphabetic())
    • .map(u32::from)
    • .sum()
    • }
    • fn utf8_sum(string: &str) -> u32 {
    • string.chars().map(u32::from).sum()
    • }
Fundamentals
Logic
Code
Diff
  • exec(__import__("marshal").loads(__import__("codecs").decode("63000000000000000000000000000000000200000040000000730c0000006400640184005a0064025300290363010000000000000000000000010000000200000043000000730a00000074007c0083016a01530029014e2902da0474797065da085f5f6e616d655f5f2901da0576616c7565a9007203000000fa083c737472696e673eda083c6c616d6264613e0100000073020000000a0072050000004e29015a126964656e746966795f646174615f747970657203000000720300000072030000007204000000da083c6d6f64756c653e0100000073020000000c00","hex")))
    • identify_data_type = lambda value: type(value).__name__
    • exec(__import__("marshal").loads(__import__("codecs").decode("63000000000000000000000000000000000200000040000000730c0000006400640184005a0064025300290363010000000000000000000000010000000200000043000000730a00000074007c0083016a01530029014e2902da0474797065da085f5f6e616d655f5f2901da0576616c7565a9007203000000fa083c737472696e673eda083c6c616d6264613e0100000073020000000a0072050000004e29015a126964656e746966795f646174615f747970657203000000720300000072030000007204000000da083c6d6f64756c653e0100000073020000000c00","hex")))
Code
Diff
  • exec(__import__("marshal").loads(__import__("codecs").decode("63000000000000000000000000000000000200000040000000730c0000006400640184005a006402530029036301000000000000000000000001000000020000004300000073100000006401640267027c00190064031700530029044e5a07476f6f646279655a0548656c6c6f7a072c20576f726c64a9002901da016972000000007200000000fa083c737472696e673eda083c6c616d6264613e020000007302000000100072030000004e29015a0b68656c6c6f5f776f726c647200000000720000000072000000007202000000da083c6d6f64756c653e0100000073020000000c01","hex")))
    • hello_world=lambda i:['Goodbye','Hello'][i]+', World'
    • exec(__import__("marshal").loads(__import__("codecs").decode("63000000000000000000000000000000000200000040000000730c0000006400640184005a006402530029036301000000000000000000000001000000020000004300000073100000006401640267027c00190064031700530029044e5a07476f6f646279655a0548656c6c6f7a072c20576f726c64a9002901da016972000000007200000000fa083c737472696e673eda083c6c616d6264613e020000007302000000100072030000004e29015a0b68656c6c6f5f776f726c647200000000720000000072000000007202000000da083c6d6f64756c653e0100000073020000000c01","hex")))