# Output the Hebrew alphabet

Your task is to print this exact text:

אבגדהוזחטיכךלמםנןסעפףצץקרשת


(You are allowed to print a trailing newline)

SHA256 hash of the UTF-8 encoding of the text:

0ab6f1e0bf216a0db52a4a5a247f95cba6f51496de7a24dfd01f3985dfcf6085


Base64 encoding:

15DXkdeS15PXlNeV15bXl9eY15nXm9ea15zXnted16DXn9eh16LXpNej16bXpden16jXqdeq


### Rules

• You can't use a builtin outputting this text.
• Standard loopholes are disallowed.
• This is , so the shortest answer wins.

Good luck!

• I noticed the code points are not directly in order. You have 1488, 1489, 1490, 1491, 1492, 1493, 1494, 1495, 1496, 1497, 1499, 1498, 1500, 1502, 1501, 1504, 1503, 1505, 1506, 1508, 1507, 1510, 1509, 1511, 1512, 1513, 1514. I don't know very much about Hebrew, so could you confirm this is indeed intentional? – DJMcMayhem Oct 21 '16 at 17:27
• @DJMcMayhem Unicode list final letters before normal letters but in the text in the question normal letters are listed before. It was not really intentional, but at least it encourage answers that are not as boring as print(map(chr, range(x, y))) – TuxCrafting Oct 21 '16 at 17:29
• אני מדבר עברית! – OldBunny2800 Oct 22 '16 at 3:34
• Aleph null, aleph one, aleph 2, ... – Kritixi Lithos Oct 22 '16 at 18:21
• @Angs That's because it really doesn't match. echo 15DXkdeS15PXlNeV15bXl9eY15nXm9ea15zXnted16DXn9eh16LXpNej16bXpden16jXqdeq | base64 -d | sha256sum produces f1d4b9c12a197912a4bdb80fb3e4d3fad5a0d9b7edd243fae7b2ab3450618036. – hvd Oct 23 '16 at 15:07

# MATLAB, 52 51 bytes

[cumsum([1488 'CCCCCCCCCDADDAEADCDAEADCCC'-66]) '']


Example use:

>> [cumsum([1488 'CCCCCCCCCDADDAEADCDAEADCCC'-66]) '']
ans =
אבגדהוזחטיכךלמםנןסעפףצץקרשת


### Explanation

'CCCCCCCCCDADDAEADCDAEADCCC'-66 produces the array [1 1 ... -1 2 1 1 1], which contains the consecutive differences between the codepoints of the desired characters.

[1488 ...] prepends 1488, so the array is now [1488 1 1 ... -1 2 1 1 1].

cumsum(...) computes the cumulative sum: [1488 1489 ... 1514].

[... ''] concatenates with the empty string. This has the effect of converting to char (and is one byte shorter than char(...))

# Jelly, 2221 20 bytes

27R+“¿ÇÑÞæ‘¦2Ụ+1487Ọ


Try it online!

### Idea

If we subtract 1487 from each code point, we get the array R that follows.

1 2 3 4 5 6 7 8 9 10 12 11 13 15 14 17 16 18 19 21 20 23 22 24 25 26 27


That's just the range from 1 to 27, but not in ascending order; the pairs (11, 12), (14, 15), (16, 17), (20, 21), and (22, 23) have been swapped.

If we take the ascending range and add 2 to 11, 14, 16, 20, and 22, we get the array A that follows.

1 2 3 4 5 6 7 8 9 10 13 12 13 16 15 18 17 18 19 22 21 24 23 24 25 26 27


This is no longer a permutation of the range, but if we stably sort the range by the values in that array, we can reconstruct the original array.

### Code

27R+“¿ÇÑÞæ‘¦2Ụ+1487Ọ  Main link. No arguments.

27R                   Yield [1, ..., 27].
¦          Conditional application:
“¿ÇÑÞæ‘             At indices 11, 14, 16, 20, and 22...
+        2           add 2 to the corresponding value.
This yields the array A from the previous section.
Ụ        Grade up; sort the indices of the result by its corresponding
values. This yields the array R from the previous section.
+1487   Add 1487 to each integer in R.
Ọ  Unordinal; convert integers to characters.


## PowerShell v2+, 58 bytes (UTF-16)

'אבגדהוזחטיכךלמםנןסעפףצץקרשת'


PowerShell Unicode is UTF-16 unless explicitly specified otherwise, and then it's a crapshoot anyway since it's all UTF-16 in the background.

This just puts the literal string on the pipeline and the default Write-Output at the end of program execution prints it to screen.

The shortest I could get the ASCII version is 63

-join([char[]]'ABCDEFGHIJLKMONQPRSUTWVXYZ['|%{[char](1423+$_)})  Which takes the ASCII value of the string ABC... and adds 1423 to each char to get the appropriate string. • Upvoted only because your ASCII version is clever. Must... support... clever... golfing! – wizzwizz4 Oct 21 '16 at 18:48 • It took me at least 5 minutes to realise that it wasn't the actual alphabet in the ASCII version. – caird coinheringaahing Dec 26 '17 at 3:24 # 05AB1E, 36292625 23 bytes Saved 2 bytes thanks to Adnan Uses CP-1252 encoding. 1488•’ÉÇW–moû•5Bvy<+Dç?  Try it online! Explanation 1488 # push 1488 (accumulator) •’ÉÇW–moû• # push 2235174277545950437 5B # convert from base-5 to base-10 (122222222230330403230403222) v # for each digit in above number y< # decrease it by 1 + # add to accumulator Dç? # print a copy of accumulator converted from code point  • Interpreting the big number as a base 5 number saves two bytes: 1488•’ÉÇW–moû•5Bvy<+Dç?. – Adnan Oct 21 '16 at 18:28 • @Adnan: Ah of course. Great thinking! – Emigna Oct 21 '16 at 18:29 # Brain-Flak, 172 bytes This answer is based largely one DJMcMayhem's solution here so I recomend you check it out. Like DJMcMayhem's solution this uses the -rA flag to reverse output and print to unicode. (((((()()()()()){})))<(((({}{}{}()){({}[()])}{})){}{})>){({}[()]<(({})())>)}{}(((((()()())((((((((({}(((({}())[()])()())()())[()]))[()])()())())()())[()]))[()])()())())())())  Try it online! ## Explanation I made this answer by running a bunch of micro-optimizations over the original solution provided by DJMcMayhem. These optimizations while saving bytes, make the code unreadable and the algorithm obtuse. I, to be honest, do not really understand how or what my code does. Perhaps someday I will understand how this works... # Python 3, 50 bytes #coding:cp862 print('אבגדהוזחטיכךלמםנןסעפףצץקרשת')  The file must be created using the CP862 encoding or by reversing the following hexdump. 0000000: 23 63 6f 64 69 6e 67 3a 63 70 38 36 32 0a 70 72 #coding:cp862.pr 0000010: 69 6e 74 28 27 80 81 82 83 84 85 86 87 88 89 8b int('........... 0000020: 8a 8c 8e 8d 90 8f 91 92 94 93 96 95 97 98 99 9a ................ 0000030: 27 29 ')  This could probably be ported to Python 2 (thus saving two bytes), but I lack the proper locale to test it. Python 3 dutifully prints an UTF-8 encoded version (or whatever is appropriate for the current locale) of the alphabet. ### Verification $ base64 > hebrew.py -d <<< I2NvZGluZzpjcDg2MgpwcmludCgngIGCg4SFhoeIiYuKjI6NkI+RkpSTlpWXmJmaJyk=
$wc -c hebrew.py 50 hebrew.py$ echo $LANG en_US.UTF-8$ python3 hebrew.py
אבגדהוזחטיכךלמםנןסעפףצץקרשת


# CJam, 23 bytes

27,"%(*.0"{i_)e\}/'אf+


Try it online!

### How it works

27,                     Push [0 ... 26].
"%(*.0"              Push that string. Its code points are [37 40 42 46 48],
which are [10 13 15 19 21] modulo the length of the string.
{     }/      For each character:
i              Compute its code point.
_)            Push an incremented copy.
e\          Swap the integers of [0 ... 26] at those indices.
'אf+  Add all resulting integers to the first character of the
Hebrew alphabet.


# Brain-Flak, 186 bytes

(((((((((((((((((((((((((((((((((()()()()()){})){}{}()){({}[()])}{})){}{})())())())())())())())())())()())[()])()())()())[()])()()())[()])()())())()())[()])()()())[()])()())())())())


This code is 182 bytes long, and I added 4 bytes for two command line flags: -r and -u

Try it online!

Many thanks to @Neil for this awesome integer metagolfer that created this sweet way of pushing 1488 (the code point of the first character)

(((((((()()()()()){})){}{}()){({}[()])}{})){}{})


Explanation:

Pushing large number in brain-flak is relatively difficult. However, since the act of pushing a number also evaluates to that number, we can push several numbers at the same time for massive byte savings. Here is a more concrete example. The innermost part (that I wrote above) in psuedo code is

push(1488)


This expression evaluates to 1488, so we wrap the entire thing in another push statement:

push(push(1488) + 1)


This pushes 1488 and 1489, as well as evaluating to 1489. So we wrap this:

push(push(push(1488) + 1) + 1)


which pushes 1488, 1489, and 1490, as well as evaluating to 1490. Repeat this step for each number we need to push.

However, since the increments aren't always 1, it's a little bit more complicated than that. Here is a more readable version:

(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
(
#Push 1488
(((((((()()()()()){})){}{}()){({}[()])}{})){}{})
())     # + 1
())
())
())
())
())
())
())
())
()())   # + 2
[()])   # - 1
()())   # + 2
()())
[()])   # - 1
()()()) # + 3
[()])   # - 1
()())   # + 2
())     # + 1
()())   # + 2
[()])   # - 1
()()()) # + 3
[()])   # - 1
()())   # + 2
())     # + 1
())
())

• I thought it is +1 for -r because the - doesn't count – NoOneIsHere Oct 21 '16 at 17:47
• @NoOneIsHere - doesn't count if it is already present from a different option (e.g. in perl -e). Brain-Flak doesn't have an existing option like that, so -, the option, and the space after all count toward the total. – Riley Oct 21 '16 at 18:01
• Just a little improvement I made brain-flak.tryitonline.net/… – Wheat Wizard Oct 21 '16 at 20:35
• @WheatWizard If I were to take that, then I wouldn't be able to write an explanation. It just looks like a jumbled mess of brackets to me. :P – DJMcMayhem Oct 21 '16 at 20:40
• Its a very small change. I just moved the two instances of ()()() to the beginning and put them down and up. – Wheat Wizard Oct 21 '16 at 20:46

# ///, 27 bytes

ABCDEFGHIQSRTVUXWYbdcfeghiq


Try it online!

Output is encoded in CP424.

To verify it yourself:

$echo ABCDEFGHIQSRTVUXWYbdcfeghiq | ./slashes.pl | python3 -c 'print(bytes(input(), "utf-8").decode("cp424"))' | base64 15DXkdeS15PXlNeV15bXl9eY15nXm9ea15zXnted16DXn9eh16LXpNej16bXpden16jXqdeqCg==  • What kind of code is this? I think it needs to be converted to UTF-8 for viewing purposes anyways. Not that it is necessarily invalid :P have a +1 – Erik the Outgolfer Oct 24 '16 at 16:18 • @EriktheGolfer There is no need to convert it to UTF-8. That is not a requirement anywhere in the challenge. – Mego Oct 24 '16 at 18:50 • I think you might attract downvotes then. Please note that, in your place, I would have included the UTF-8 version and a hexdump of the original... – Erik the Outgolfer Oct 25 '16 at 10:36 ## JavaScript (ES6), 59 bytes _=>"אבגדהוזחטיכךלמםנןסעפףצץקרשת"  Best I could do in ASCII was 80 79 78 bytes: _=>String.fromCharCode(...[...0x377babbcf7f.toString(3)].map(c=>++n-c,n=1488))  If a character array is acceptable, 75 bytes: _=>[...0x377babbcf7f.toString(3)].map(c=>String.fromCharCode(++n-c),n=1488)  Edit: Saved some bytes thanks to @IsmaelMiguel. Saved another byte thanks to @ETHproductions. If you use Firefox 30-57 then you can save another 2 bytes thanks to @ETHproductions using generator or array comprehensions: _=>String.fromCharCode(...(for(c of 0x377babbcf7f.toString(3,n=1488))++n-c)) _=>[for(c of 0x377babbcf7f.toString(3,n=1488))String.fromCharCode(++n-c)]  • You can save a byte on your ASCII alternative by using 0x377BABBCF7F.toString(3). Combinig this with .map(), you can do _=>0x377BABBCF7F.toString(3,n=1488).split.map(_=>String.fromCharCode(++n-_)) for 78 bytes. It returns an array of characters. – Ismael Miguel Oct 21 '16 at 21:41 • @IsmaelMiguel Nice catch on the .. but we don't use split around here. – Neil Oct 21 '16 at 23:42 • Nice. You can modify the char-array version slightly to get _=>String.fromCharCode(...[...0x377babbcf7f.toString(3)].map(c=>++n-c,n=1488)), 1 byte shorter than the current 79 bytes. – ETHproductions Oct 22 '16 at 0:01 • @ETHproductions Bah, I had played around with String.fromCharCode(...) and had managed to convince myself that it would always be longer. In fact it saves 4 bytes on my base 2 solution (which is still 84 bytes because it takes more bytes to decode). – Neil Oct 22 '16 at 0:16 • If you're willing to use array comprehensions, you can get 2 bytes off of each; string: _=>String.fromCharCode(...[for(c of 0x377babbcf7f.toString(3,n=1488))++n-c]), char-array: _=>[for(c of 0x377babbcf7f.toString(3,n=1488))String.fromCharCode(++n-c)) – ETHproductions Oct 22 '16 at 0:59 # 05AB1E, 28*2-1=55 bytes "אבגדהוזחטיכךלמםנןסעפףצץקרשת  Try it online! -1 byte thanks to Emigna + 28 bytes thanks to DJMCMayhem ;). • I don't know what encoding 05AB1E uses, but I highly doubt those are one byte chars in whatever it is. – DJMcMayhem Oct 21 '16 at 17:30 • @DJMcMayhem I think TIO has a bug, those characters don't exist in CP-1252. – Erik the Outgolfer Oct 21 '16 at 20:37 • @EriktheGolfer Most likely it uses UTF-8 for convenience and then the 05AB1E interpreter does the necessary internal conversion. That's what I do for V (which uses latin1). – DJMcMayhem Oct 21 '16 at 20:39 • @DJMcMayhem Here it is shown as UTF-8 I think, but it also supports CP-1252, which you can use to make your byte count lower. This is not pure CP-1252, though, so it must be run with UTF-8 strings. – Erik the Outgolfer Oct 21 '16 at 20:41 # ///, 54 bytes אבגדהוזחטיכךלמםנןסעפףצץקרשת  Try it online! There can't be any version more golfed than this :( # Scala/Groovy/Python 3, 9 ascii-chars + 27 2-byte chars = 63 bytes print("אבגדהוזחטיכךלמםנןסעפףצץקרשת")  assuming UTF-8 # Scala, 59 bytes print("ABCDEFGHIJLKMONQPRSUTWVXYZ["map(x=>(x+1423).toChar))  x+1423 is the same as x-'A'+1488 • Polygot, it works in Groovy too; also, see my answer, bytecount is off. – Magic Octopus Urn Oct 21 '16 at 19:39 • also in python 3 (also python 2 but then the parenthesis aren't necessary) – user49822 Oct 21 '16 at 19:46 • @caruscomputing I'd be wary of editing another user's byte count because you assume a certain encoding. Are you sure Scala can or can only handle UTF-8? Also, the Hebrew alphabet has 27 letters, so 61 is wrong one way or another. – Dennis Oct 21 '16 at 20:11 • The first option also works on PHP. – Ismael Miguel Oct 21 '16 at 22:04 # APL (Dyalog), 35 bytes d←⍳27 d[⎕A⍳'KNPTV']+←2 ⎕UCS 1487+⍋d  Try it online! • you can encode 11 14 16 20 22 as ⎕A⍳'KNPTV' – ngn Dec 27 '17 at 11:16 # C#6+, 7686 82 bytes void f()=>Console.Write("אבגדהוזחטיכךלמםנןסעפףצץקרשת");  First attempt at Golfing. Am I doing this right? EDIT: +6 bytes for forgetting to enclose in a function. Thanks @Kevin # C#5 and below version, 86 82 bytes void f(){Console.Write("אבגדהוזחטיכךלמםנןסעפףצץקרשת");}  • Actually, you should either print a function or a complete program. So void F(){Console.WriteLine("אבגדהוזחטיכךלמםנןסעפףצץקרשת");} would be valid, or ()=>{Console.WriteLine("אבגדהוזחטיכךלמםנןסעפףצץקרשת");} as well I think (not sure about this last one, though). Also, you can golf it by using .Write instead of .WriteLine. :) That being said, welcome to PPCG! You may find Tips for golfing in C# interesting to read through. Enjoy your stay. – Kevin Cruijssen Oct 24 '16 at 7:37 • You know, you can use <s>your text</s> to strike some text instead of using strange characters. – Erik the Outgolfer Oct 24 '16 at 15:28 • I wasn't aware about that. Anyway thanks @EriktheGolfer – terrible-coder Oct 24 '16 at 23:26 # Fourier, 53 bytes |+2a|X1488~i+10(ia^~i)^avaXXva+3avaX^aXva+3avaX^a^a^a Uses functions again. Try it FourIDE! # ArnoldC, 112 bytes IT'S SHOWTIME TALK TO THE HAND "אבגדהוזחטיכךלמםנןסעפףצץקרשת" YOU HAVE BEEN TERMINATED  ## Keg, 34 bytes Inspired by a Powershell solution. ZYXVWTUSRPQNOMKLJIHGFEDCBA(֏+")(,  TIO # BaCon, 57 bytes • In most BASICs, the question mark simply represents PRINT. • At first glance, the solution below looks like 30 bytes, but the Hebrew characters need 2 bytes of storage because of UTF-8. So there are 27 characters x 2 bytes + 1 byte for the '?' and 2 bytes for the double quotes = 57 bytes. Solution: ?"אבגדהוזחטיכךלמםנןסעפףצץקרשת"  • Try GW-BASIC with a CP862 VGA BIOS for 30. (Same text) – Joshua Oct 21 '16 at 21:48 # s-lang, 59 bytes Really simple answer... t[][אבגדהוזחטיכךלמםנןסעפףצץקרשת]  • t - replace function (replaces "nothing" in the input with the alphabet...) ## Try it here # zsh, 25 21 bytes echo${(j..):-{ת..א}}


My browser is messing it up: the ת should be the first letter, then the א. If you paste somewhere else, though, it should work. The old version:

for i in {ת..א};printf $i  • Invalid, because final letters and normal letters are reversed in Unicode – TuxCrafting Oct 22 '16 at 18:58 • Also, it's actually 27 bytes – TuxCrafting Oct 22 '16 at 18:59 • Oh and the range should actually be aleph first and tav last. If the string is reversed in the question, it's because Hebrew is an RTL language – TuxCrafting Oct 22 '16 at 19:04 • @TùxCräftîñg in my terminal, it displays correctly only with taf first an aleph last. What do you mean "final letters and normal letters are reversed in Unicode"? – Elronnd Oct 22 '16 at 19:14 • In the text in the question, there is כך for example (normal kaf first, final kaf second), but in Unicode, final letters are before normal letters (ךכ), so the printed text in invalid. And if it display with tav first, it's because Hebrew is a RTL language, so the first character is displayed rightmost – TuxCrafting Oct 22 '16 at 19:26 # Java 7, 85 bytes void c(){System.out.print("אבגדהוזחטיכךלמםנןסעפףצץקרשת");}  I'm not even gonna bother posting test code or a 'Try it here' like I usually do.. ## Perl 6 (74) (map (*+1488).chr,[\+] '122222222230330403230403222'.comb >>->>1.join.say  # Ruby, 49 bytes -11.upto(15){|r|$><<(""<<r+1499-2601[r]+5202[r])}


Try it online!

# Haskell, 23 bytes

main=putStr['א'..'ת']


Try it online!

This works in TIO's version of Haskell

# C, 49 bytes

f(i){for(i=0x5d0;i<=0x5ea;i++)wprintf(L"%lc",i);}


Some users may need to call setlocale before using this but it worked fine for me.

• Suggest for(i=1488;putwchar(i++)<1514;); instead of for(i=0x5d0;i<=0x5ea;i++)wprintf(L"%lc",i); – ceilingcat May 10 at 1:04

# Clean, 62 bytes

Start="אבגדהוזחטיכךלמםנןסעפףצץקרשת"


Try it online!