Programming @4-ch

Programming @4-ch

Be it HTML, C++, Java or whatever language you prefer, programming is what we do best around this board.
Markup languages are also fine around here, as with all the "not so real" languages of Shell script, CSS, and other various third party scripting languages.
  • We are sick of language discrimination, more so the PHP/Java bashers. There will be little tolerance of blatant and repetitive insults. You are still welcome to bring forward a sensible, insult-free argument regarding a certain topic at the appropriate time and place for it.
  • Please use WakabaMark or the appropriate HTML tags (with HTML enabled, of course) to format your code.
Rules · 規則
基本的には英語の使用を強く希望します。ただ日本語板の場合は日本語か英語。
Board look: Blue Moon Buun Futaba Headline Mercury Pseud0ch Toothpaste

Is Ruby as inefficient as they say (2)

1 Name: #!/usr/bin/anonymous : 2013-05-04 05:49 ID:pe6UtPea

I'm looking into mobile development, and Ruby looks really nice, but I heard it's fairly slow. Is it really as bad as they say? If I don't use Ruby, and I absolutely hate Java, what's a good language for developing software for Android?

2 Name: #!/usr/bin/anonymous : 2013-05-09 22:49 ID:Heaven

Ruby is fairly slow, but much of what you see on the internet about it is exaggerated.

> If I don't use Ruby, and I absolutely hate Java, what's a good language for developing software for Android?

Clojure or C.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

Introduction to complexity and the idea od quantum computers (2)

1 Name: #!/usr/bin/anonymous : 2011-06-20 10:48 ID:8Esf3C5Z

This is rather cool:

"Quantum Computing and the Limits of the Efficiently Computable - 2011 Buhl Lecture"

http://www.youtube.com/watch?v=8bLXHvH9s1A

Link contribs?

2 Name: #!/usr/bin/anonymous : 2013-04-08 14:44 ID:El6PKSVm

if you care so much about those real people i suppose you give them your lunch money, not mine

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

Opinions of Codecademy? (8)

1 Name: #!/usr/bin/anonymous : 2012-10-29 14:47 ID:A/bsuojT

I'd really like to use the site http://www.codecademy.com to start learn Javascript and then go on to either Python or Ruby. To more experienced programmers or anyone who has tried the site, what do you think of it? I realize I'm not going to be a Ruby wizard in a month, but is it good for what it does?

Also, I am somewhat concerned about their privacy policy. ( http://www.codecademy.com/policy ) It seems really ambiguous and their signup page has built-in Facebook/google integration. So I feel kind of wary to sign up of give them any of my information.

2 Name: #!/usr/bin/anonymous : 2012-10-29 16:00 ID:QERsyNf4

I'm using it at the moment OP, I think it's a good introduction, and the Q&A forum is helpful if you get stuck.

3 Name: #!/usr/bin/anonymous : 2012-10-30 17:03 ID:UTJWSg78

OP, the most important thing is that you do it consistently. Just keep practicing. I haven't used codeacademy, but I'm sure it's just fine for an introduction.

Although, OP, you would probably be just fine jumping right into Python or Ruby, because they're relatively user friendly.

4 Name: #!/usr/bin/anonymous : 2012-11-01 14:17 ID:GCQAnVl1

>>2>>3
Thanks.

So once I'm done with JS, which should I take, Ruby or Python?
I am more interested in writing Web-related things.

5 Name: #!/usr/bin/anonymous : 2012-11-04 08:55 ID:4BUdibj3

>>4
They are equally capable of web-related things. Ruby is more popular for such things, but that's mostly because Ruby on Rails is more or less what made the language famous.

I suggest trying some small things (puzzles, toy applications) in both and choosing the one you like.

6 Name: #!/usr/bin/anonymous : 2013-03-09 03:41 ID:PIes3y5M

I use code academy, i gotta read that privacy policy :p

7 Name: android dev : 2013-03-27 20:42 ID:k58uh+++

Hello Guys,

i am progamming android apps for 2 month. Now i already have 2 apps. I
am progamming android apps because i want to improve my java
knowlegde.

My apps are free and there is no advertisement in it. So i dont make
any money with these apps, but that is not important for me. I focus
on learning programming and its great!

If more people would download my apps and give me feedback, i would be
able to improve it. Besides that it would give me more motivation to
make more and even better apps! :)

My first app is called "BONGI" and my second is called "GROBI".

Post too long. Click to view the whole post or the thread page.

8 Name: SomeAnon : 2013-04-04 01:55 ID:/zEVA4yC

>>7
cool beans

        ... .... ..... . ..................     ........... . ..            
..+$?I777I?$... ...+====:::~=?,.. . ....++======+...
....Z7ZZZZ$$$$ZZ$I....$=I7$$ZZ$7+=::+........I=:,::,,,,..:+,....
..:7ZZZ$7?+~,,~+ZZI..$IZ$ZZZZZ$=..++:+......?$O+,,:I=+=~:,.:?..
..7OOZ$7?+++=:,,+Z77.?8ZZZZZZZ$+..:?=~I....+~=+~,~+?O=:,.,:.=,..
.$OOZ$77?++++=:,=$$?778ZZZZ$ZZZ$=.:+I==O..,DD?+==+=++=:,..:,,?..
.$OO$$$$I?++++::+$$I$$8$ZZZZZZZZ$I+?7$8$,.N$NMMONMNNNO=:.:~:,?..
+8OO$$$$7I++++~~?$Z7778Z$+ZZZO8OZ$I?8D+++.8ZNM?+?MNNDOMD?~:,,?..
Z8OZ7$ZZ$7I+D8ND?$N8?78ZDOZZZZNDO7ZZZ$7=+:I,+7ZI+?NN$O~,~+:,,?..
. ..NM877$ZZZ88$??==I$Z$,I8Z$Z$ZMMMNOI8Z777I=?+~?ZMNN+++++=,~~,.:+..
...ZNNZO8OOO8888DZ=IZ$N8D8NNMMN8MMMN8Z$777$=O$ZII887++++++~,~,.:O..
....$8ZI7ZDNMNNNMD$$MNMNN8MDNMMD7$O$$8$$$$$$$?DZ7Z$?+++++++=:~,.I?..
Post too long. Click to view the whole post or the thread page.
Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

Interpreted vs. compiled labguages (25)

1 Name: #!/usr/bin/anonymous : 2011-03-07 12:48 ID:Aep/pjix

Would you say it's easier for a newbie to pick up programming by learning an interpreted language ?

16 Name: #!/usr/bin/anonymous : 2012-06-18 13:30 ID:nCLwiqu9

17 Name: #!/usr/bin/anonymous : 2012-07-01 01:26 ID:E6kT7erT

ITT: Pussies who don't have the brain plasticity to learn assembly

18 Name: #!/usr/bin/anonymous : 2012-07-04 00:51 ID:Heaven

>>17
I wasted all my grey matter on eroge and 4chan, leave me alone.

19 Name: #!/usr/bin/anonymous : 2012-09-14 05:23 ID:6GcFPCrk

>>13
ASM is not a clusterfuck. C and its undefined behavior is a clusterfuck.

20 Name: #!/usr/bin/anonymous : 2012-10-09 13:52 ID:hKPHxe0D

>Would you say it's easier for a newbie to pick up programming by learning an interpreted language ?

I would say it depends on what are you like/want to do more.
I'd recommend starting with PHP and continuing with C. Because it's easy.

21 Name: #!/usr/bin/anonymous : 2012-10-20 13:39 ID:77BK0eUh

>>19

I dare to object. Every self-respecting C compiler should spill warnings about UB, until you bend over. To top it off for a bit, stronger typing of C++ treats some UB as hard errors (while creating plethora of new ones in it's wild-west approach to OO).

22 Name: #!/usr/bin/anonymous : 2012-11-24 14:31 ID:/vjq3rnG

>>20
Please don't start with PHP, for the love of God. That is the worst thing anyone could do.

23 Name: #!/usr/bin/anonymous : 2012-11-24 22:29 ID:Heaven

>>22
I mean, feel free to learn it at some point as I fully understand it is necessary to know in some lines of work, but to learn it as a first language will give you bad habits that are hard to drop if they're the first things you learnt.

I recommend learning Scheme while reading SICP. It will start you off with a nice, high standard. Python is okay too if you would rather.

24 Name: #!/usr/bin/anonymous : 2012-11-29 18:32 ID:7Bu9YmDM

>>20
No, oh my god no. PHP is no. Just no.
Is you want to pick up an actual language that is easy, go with Python or Ruby.

25 Name: #!/usr/bin/anonymous : 2012-12-06 19:55 ID:Rm+oYDsT

PHP is an actual programming language. It is, however, not a general-purpose programming language.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

Programming languages with fast matrix operations (15)

1 Name: #!/usr/bin/anonymous : 2011-03-19 21:56 ID:hBekoLl7

Sup. Can you guys show me a list of PL's that have fast/easy matrix operations. I am thinking of languages like Matlab where you can play with matrices, multiply, do eigen analysis, etc. without having to do loops and so on. I am working with mostly 3D data right now, so the ability to view 3D images would be nice too. Also nice would be if it came with libraries that have geometry stuff like triangulation, convex hull, and so on.

6 Name: #!/usr/bin/anonymous : 2011-09-24 19:54 ID:trzXDjoh

>>4
I am doing research in 3D vision. I actually do use R for the simple statistics stuff that I do. It's quite useful in that regard but I don't think I can write larger programs using it. It's too messy. For the 3D stuff, right now I am using C++ with VTK and sometimes OpenCV. And trying to use Ocaml whenever possible. Though from the looks of it, I am just going to end up with Matlab due to the amount of relevant code that I can use.

Openframeworks seems interesting, I'll look into it, thanks.

>>5
The concepts used in J is pretty amazing but no way will I be able to use it and be sane.

7 Name: #!/usr/bin/anonymous : 2012-06-19 14:13 ID:rnZVfANB

How about Fortran? :-þ

8 Name: #!/usr/bin/anonymous : 2012-07-10 20:33 ID:qZ0VOJgt

>>7
Hell yeah.

9 Name: #!/usr/bin/anonymous : 2012-08-29 19:31 ID:M+zF+icO

With C++ you can try the Eigen library, it seems pretty good.

10 Name: #!/usr/bin/anonymous : 2012-08-31 13:04 ID:tr5ggSOD

11 Name: #!/usr/bin/anonymous : 2012-09-14 05:14 ID:YTZ7lFrC

u w0t m8

12 Name: #!/usr/bin/anonymous : 2012-09-14 05:15 ID:YTZ7lFrC

If you buy MATLAB, you can call MATLAB functions...I don't know how.

13 Name: #!/usr/bin/anonymous : 2012-09-29 05:40 ID:Heaven

A crusty old neckbearded Unix hacker I knew a few years back had very fond memories of programming in APL as a university student. I wish I could have told him about J at the time, as he wasn't even aware that anyone had made an open source APL interpreter.

14 Name: #!/usr/bin/anonymous : 2012-11-14 22:54 ID:POkW8UHb

Pure looks nice, what do you guys think? It's a functional language, so that's nice, and has matrix support. It interfaces with lots of things including OpenCV and Octave (an open source attempt at Matlab).

15 Name: #!/usr/bin/anonymous : 2013-01-04 04:19 ID:Heaven

As a general policy, the more niche a language is, the more problems you'll have using it -- more compiler bugs, fewer libraries, less documentation, fewer debug and profiling tools, and so forth. As such, Pure isn't in the running yet.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

OOP vs functional (9)

1 Name: #!/usr/bin/anonymous : 2011-03-26 13:11 ID:tubYEjxP

in layman's terms what is the difference between the two ?

2 Name: #!/usr/bin/anonymous : 2011-03-26 21:22 ID:fy1QcJq/

Functional programming isn't the direct opposite of OOP, but of imperative programming. Imperative programming operates on the principle that programs have a global 'state' which should be manipulated to produce the desired results, while functional programming attempts to avoid state and treat all data and program flow as interactions between functions. Having no state is often described as being "functionally pure" or "no side effects."

To use an example, consider possible programs in an imperative and functional style:

def x_plus_three(x):
y = 42 # this would be a side effect
# it's poor programming, but the language won't stop you
return x + 3

Algebra, while not technically a programming language, is indeed functional:

f(x) = x + 3

Notice that using algebra, you couldn't change the value of y from within a function that operates only on x. Purely functional languages are subject to the same constraint- in fact, they don't actually 'change' anything at all, they merely produce brand new outputs by performing calculations on their inputs. This prevents errors in case you didn't want y to become 42 or x to permanently increase by three.

Post too long. Click to view the whole post or the thread page.

3 Name: #!/usr/bin/anonymous : 2012-01-26 01:47 ID:auY5imFY

Functional isn't opposite of OO, because there is functional OO.

OO with immutable objects is functional. (States can still be represented by creating new objects based on old ones.)

From a functional point of view, OO is a way of organizing the types into classes which are tuples of properties optionally linked by inheritance relationships, and of dispatching methods based on class-based pattern matching over the argument lists.

Functional OO is "cleaner" than regular OO in some ways. For instance circle-ellipse issues don't arise, because you can't mutate a circle or ellipse once it is constructed.

4 Name: #!/usr/bin/anonymous : 2012-04-11 02:57 ID:x2KjDRnY

>>3

> circle-ellipse issues don't arise, because you can't mutate a circle or ellipse once it is constructed.

I don't believe you here. You can still make a copy of some object A, and call it B. Hell, you can even call it A with a let statement.

5 Name: #!/usr/bin/anonymous : 2012-07-17 22:25 ID:n43w4UzA

I had an interesting realization on the nature of OOP once. When you think about it, it effectively models multiple computers running programs and interacting with each-other.
Even in game programs you have the 'view' model where one ticks each registered object in the main loop - it can be viewed as multiple processors being 'ticked' to the next CPU cycle.

6 Name: #!/usr/bin/anonymous : 2012-08-27 12:46 ID:BkDUZxkD

>>3
Pure OOP [i]is[/i] the opposite (dual) of pure FP. OOP is modeled by terminal coalgebras, FP by initial algebras. The distinction you're making is imperative vs declarative.
To solve the ``Expression Problem'', you need both.

7 Name: #!/usr/bin/anonymous : 2012-08-27 12:47 ID:Heaven

>>6
is

8 Name: #!/usr/bin/anonymous : 2012-10-08 20:33 ID:g8LKidg7

OOP is not needed in most small projects as it only complicates understanding of the code and, as a result, increases time spent on its' reading and monies spent on its' support.
OOP makes life easier when dealing with something really obstructive. Instead of making clusterfuck of dynamically loaded modules and thousands functions in the global namespace, you simplify (or trying to) program structural organization, dividing it into classes and objects. Saves lots of time when amount of actual developers is more than 3.
Oh, and, of course:

object->doSomething(whatever);
doSomething(object, whatever);

9 Name: #!/usr/bin/anonymous : 2012-10-20 13:51 ID:ExnosPyy

Note that variables captured in closures/continuations are technically equivalent to instances of which all members, including methods are private - and only visible to child classes defined in it's own scope (NOT derived classes, protected: is a sideffect).

In the same vein closures are just class instances without sideffects (are we comparing to pure-functional, right?).

Btw, this is clearly visible in C++11 and it's implementation of lambdas.

However nobody uses pure functional style, nor OO with such a rigid encapsulation. Both are most widely deployed in multi-paradigm systems, on that level, they could be IMO treated as equal.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

[JS] Help me find out the correct speed to sync up with the song 太陽いわく燃えよカオス (5)

1 Name: #!/usr/bin/anonymous : 2012-08-10 08:31 ID:2Uhzsz2B

Hi, so a friend made this for me after I linked them to the Nyaruko-san OP on YouTube. He said that using the + and - buttons, it ought to sync up with any beat.
My apologies if I mesed up the indentation in the following copypaste:

<html>
<head>
<title>(」・ω・)」うー!(/・ω・)/にゃー!</title>
<script type="text/javascript">var speed = 250;
var looper = setInterval(function(){ u.style.display="inline";
nya.style.display="none";
setTimeout(function(){ u.style.display="none";
nya.style.display="inline";
},speed);
},speed*2);
function unya(){
Post too long. Click to view the whole post or the thread page.

2 Name: #!/usr/bin/anonymous : 2012-08-10 08:32 ID:2Uhzsz2B

I should probably add that the title of the Nyaruko-san OP is 太陽いわく燃えよカオス.

3 Name: #!/usr/bin/anonymous : 2012-08-10 08:33 ID:2Uhzsz2B

err, not 太陽いわく, but 太陽曰く. My apologies.

4 Name: #!/usr/bin/anonymous : 2012-08-14 21:35 ID:owHAmwwP

I think Audacity has a beat-matcher built in. That is, it can detect the BPM of a song. I used it to make StepMania simfiles.

Also, you should send this to Tokiko when it's finished (if you're not him).

5 Name: ni : 2012-08-25 07:41 ID:vzwhkGjH

http://ieserver.net/

roujinkai dip.jp pass//// 4rfv6yhn1qak

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

my own "yet another imageboard-script" (105)

1 Name: #!/usr/bin/anonymous : 2007-02-26 01:26 ID:Hw07jnmQ

So - I promised a friend to set up a imageboard for him, but I quickly realized that the only good (open source) imageboard out there is written in Perl.

I didn't take long before I got hooked on the idea of writing my own board.
I have to admit I'm a ruby fanboy (no flameing please :) ), but that doesn't change the fact that 90% of webhosts out there only supports PHP, so I decided to write it in PHP5/MySQL5.

Yesterday I had my first, sort of, working release which I really would like some feedback on.

It's not, in any way, intended to be used in real life yet, but I some of you would help me download it, test it, report problems, give feedback, suggestions etc. etc. etc. It would be really cool :)

thanks in advance

oh yeah - and the URL to the project page is: http://code.google.com/p/4chandk/

96 Name: #!/usr/bin/anonymous : 2011-01-25 16:08 ID:Wt2vPB6b

sir database is not working. there is a problem with the "ban" table

97 Name: #!/usr/bin/anonymous : 2011-01-25 20:10 ID:Heaven

Oh hey, I remember this thread. It was stupid.
Thanks >>96 for letting us relive stupid moments of internet history.

98 Name: AcompleteNOOB-jk : 2011-11-13 20:41 ID:d4ZlCwEu

Okay here is some software that supposedly does imageboard, forum and cms all rolled into one, they went offline for like 2 days but their back check it..

www.rateitstar.com/software.php

some guy who calls himself Ere wrote it, lol, but the software is some serious hot shit..

99 Name: #!/usr/bin/anonymous : 2011-11-14 05:50 ID:OxEDdlIY

>>98
I'd be embarrassed if my name was associated with something that bad.

100 Name: AcompleteNOOB-jk : 2011-12-29 03:15 ID:mc6O8Y7d

lol

101 Name: #!/usr/bin/anonymous : 2012-06-17 19:29 ID:uXTwXzlw

102 Name: #!/usr/bin/anonymous : 2012-07-20 21:22 ID:93/NkD8C

Lets talk about the state of things in the imageboard script world today.

Is it true TinyIB was another attempt at making an imageboard script by the guy who made Trevorchan, Kusaba, etc.?

Is TinyBoard's development halted forever? Did anyone ever find out where it stands compared to Wakaba in terms of both speed and security?

Has anyone found any unpatched security holes in Wakaba yet?

What exactly happened to STI?

Are there any new contenders (not forks of other scripts) in the great imageboard script race?

103 Name: #!/usr/bin/anonymous : 2012-07-22 21:12 ID:Heaven

104 Name: #!/usr/bin/anonymous : 2012-08-06 15:18 ID:93/NkD8C

>>103
Jesus fuck I'd love to see this thing in action.

105 Name: #!/usr/bin/anonymous : 2012-08-06 15:18 ID:Heaven

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

"4tran"? (52)

1 Name: #!/usr/bin/anonymous : 2008-01-02 08:24 ID:x3wju2qA

I don't know too much about programming, but I am curious about this: Is it possible to make a 4chan (or any *chan) site, however simple it may be, in fortran? I seriously doubt it, but hey, that's what I asked for.

43 Name: #!/usr/bin/anonymous : 2011-09-02 22:41 ID:Heaven

FOOGERTS

44 Name: #!/usr/bin/anonymous : 2011-09-09 20:54 ID:Heaven

frogettes

45 Name: #!/usr/bin/anonymous : 2011-09-17 02:05 ID:Heaven

Baguettes

46 Name: #!/usr/bin/anonymous : 2011-09-25 22:57 ID:Heaven

fat gits

47 Name: #!/usr/bin/anonymous : 2011-10-03 02:29 ID:Heaven

FAT GITS

48 Name: #!/usr/bin/anonymous : 2011-12-21 23:02 ID:Heaven

Gadgots

49 Name: #!/usr/bin/anonymous : 2012-01-26 01:40 ID:K0BjkvGN

If you want to be cool and challenge yourself, write the website not in "modern" Fortran, but in Fortran 66 or Fortran 77 <- DUBS languages!!!

7^2 GET

50 Name: #!/usr/bin/anonymous : 2012-04-20 21:13 ID:Heaven

51 Name: #!/usr/bin/anonymous : 2012-07-31 16:35 ID:5/0f+pg0

check out Factor http://factorcode.org/

52 Name: #!/usr/bin/anonymous : 2012-10-20 14:12 ID:Heaven

Well, it's obvious there is just not enough love for trans-fortran programmers. Every link google knows for "THE" operation (C->F translator, so you can compile regular cgi/php) is 404.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

Spoilers in Wakaba (16)

1 Name: #!/usr/bin/anonymous : 2011-11-15 16:37 ID:vXrur0sV

So I'm trying to add spoiler support in Wakaba, and I'm having a lot of trouble that I think is stemming from regex. I'm new to perl, so this is a bit hard for me. I'm adding the following to sub do_wakabamark($;$$) to accomplish this:

elsif(/^\[spoiler\]/) # spoilers{
if ($lines[0]=~/^\[spoiler\](.*)/){
while !($lines[0]=~/\[\/spoiler\]$/){
push @spoiler,$1; shift @lines;
}
}
$res.="<span class='spoiler'>".(join "<br />",@spoiler)."</span>";
}

Thanks in advance!!

7 Name: Mr. Manager!!vBeIv0NZ : 2012-02-03 04:31 ID:rbxt0snr

>>135-141
So I FINALLY got spoilers working properly. I don't remember who told me, but the only way to get this to work without completely rewriting wakabamark was to hold off on the spoiler function until AFTER all wakabamark related things were completed. Anyways, I went ahead and put my code right after:

    # restore >>1 references hidden in code blocks
$comment=~s/&gtgt;/&gt; &gt;/g;

...which was on line 846 in my version of wakaba.pl. Next is the actual spoiler code:

    # new spoiler code (can't put it in 'do_wakabamark' because of 'do_spans' messing with the order of tags
if($comment=~/.*\[spoiler\].*/){
$comment=~s/\[spoiler\]*/\<span class\=\'spoiler\'\>/g;
$comment=~s/\[\/spoiler\]*/\<\/span\>/g;
$comment=~s/\<span class\=\'spoiler\'\>\<br \/\>/\<span class\=\'spoiler\'\>/g;
$comment=~s/\<\/span\>\<br \/\>/\<\/span\>/g;
Post too long. Click to view the whole post or the thread page.

8 Name: #!/usr/bin/anonymous : 2012-02-08 02:56 ID:DZ2UrGTF

>>7
I use Kareha so it is probably not useful to me, but I am thankful that you came back to share the code with other Wakaba users.

9 Name: xenu : 2012-02-19 15:25 ID:/rDAX+RF

Don't fucking parse BBCode with regex!

10 Name: #!/usr/bin/anonymous : 2012-02-28 05:08 ID:7o0JyRUH

I actually wasn't aware that this was doing this until I read this post. After changing some code around (thanks to your example) I have fixed the problem with my bbcodes that I didn't even know was a problem until now.

Thank you!

11 Name: #!/usr/bin/anonymous : 2012-06-01 19:25 ID:Heaven

>>9
It's just one BBCode tag and it creates SPAN tags. You should take your meme-spewing elsewhere.

12 Name: #!/usr/bin/anonymous : 2012-07-25 03:56 ID:j5RC6tZ3

Bump, hopefully someone has gotten spoiler tags in Kareha.

13 Name: #!/usr/bin/anonymous : 2012-07-25 04:05 ID:j5RC6tZ3

I found a 2006 post:
# do <span class="spoiler">
$line=~s{ (?<![0-9a-zA-Z\*_\x80-\x9f\xe0-\xfc]) (~~) (?![<>\s\*_]) ([^<>]+?) (?<![<>\s\*_\x80-\x9f\xe0-\xfc]) \1 (?![0-9a-zA-Z\*_]) }{<span class="spoiler">$2</span>}gx;

Sorry.

14 Name: #!/usr/bin/anonymous : 2012-10-08 20:34 ID:Heaven

Please, use %%spoiler%% instead of BB-like tags.
Percent symbols feel better.

15 Name: #!/usr/bin/anonymous : 2012-11-24 14:34 ID:Heaven

>>14
But then how would you do nested spoilers? They are fun.

16 Name: #!/usr/bin/anonymous : 2013-03-17 20:49 ID:Heaven

Now you have two problems.

Name: Link:
Leave these fields empty (spam trap):
More options...
Verification:

New thread

Title:
Name: Link:
Leave these fields empty (spam trap):
More options...
Verification: