arisuchan    [ tech / cult / art ]   [ λ / Δ ]   [ psy ]   [ ru ]   [ random ]   [ meta ]   [ all ]    info / stickers     temporarily disabledtemporarily disabled

/λ/ - programming

structure and interpretation of computer programs.

formatting options

Password (For file deletion.)

Help me fix this shit.

Kalyx ######

File: 1519258436180.png (42.15 KB, 781x464, csharp.png)


Learning C# at the moment. Can't say I hate it too much,,,
short x = 2;
short y = 2;
// short z = x + y;         -- won't compile
short z = (short) x + y // correct

This makes me laugh though. While x and y are both shorts, the result of their addition at runtime will implicitly be given the type int, and so requires an explicit cast to be assigned to another short. I understand nobody really needs to be working with shorts in C#, and if memory efficiency at that level is something you're worried about, then the bloat from the C# runtime will eat up way more memory that you'll be "saving" by using shorts instead of a 32bit or 64bit number. Still though, this makes me chuckle.

Can't say I dislike the language itself so far honestly; though I prefer a lower level language. While easy to learn and work with, it's no fun at all. The biggest drawback for me being that it's primarily a language used on windows. Who the fuck wants to use, develop for, or (god forbid) develop on windows?

Anyone else have thoughts / opinions / horror stories or just quirky anecdotes relating to C#?
12 posts omitted. Click reply to view.


note that he said
> (I doubt that's actually why;


You don't have to guess, the Common Language Infrastructure standard clearly says at $I.12.1 that it's because the stack can only hold
native int
The CLI model uses an evaluation stack. Instructions that copy values from memory to the evaluation stack are “loads”; instructions that copy values from the stack back to memory are “stores”. The full set of data types in Table I.6: Data Types Directly Supported by the CLI can be represented in memory. However, the CLI supports only a subset of these types in its operations upon values stored on its evaluation stack — int32, int64, and native int. In addition, the CLI supports an internal data type to represent floating-point values on the internal evaluation stack. The size of the internal data type is implementation-dependent. For further information on the treatment of floating-point values on the evaluation stack, see §I.12.1.3 and Partition III. Short numeric values (int8, int16, unsigned int8, and unsigned int16) are widened when loaded and narrowed when stored. This reflects a computer model that assumes, for numeric and object references, memory cells are 1, 2, 4, or 8 bytes wide, but stack locations are either 4 or 8 bytes wide. User-defined value types can appear in memory locations or on the stack and have no size limitation; the only built-in operations on them are those that compute their address and copy them between the stack and memory.
Most importantly:
>However, the CLI supports only a subset of these types in its operations upon values stored on its evaluation stack — int32, int64, and native int.
>Short numeric values (int8, int16, unsigned int8, and unsigned int16) are widened when loaded and narrowed when stored.


I wasn't confused on why C# does it; but on why he said it made sense or was logical regardless of C#'s implementation details.


File: 1534958370507.png (205.61 KB, 622x494, gopher_joke.png)

OP here, ironically I now work in .NET; guess it just goes to show sometimes learning for learnings sake pays off anyway.



Have you tried GoLang by the way? Did you get your .NET cert anywhere? I saw some courses I could follow online, and I really loved C back in the day, before Java was forced to us by our college.

Nowadays I'm spending a lot of time learning go and I never get to hear any negatives about the language.

File: 1494642140964.gif (700 B, 79x76, wiki.gif)


This is a appreciation thread.
Are there any lainons who (like myself) won't stop finding themselves lost in depths of the wiki - TheFirstWikiOnTheWeb?
Volumes of ancient wisdom (presumably, compiled almost exclusively by SmalltalkWeenies) are open for everyone to read - and to learn from.
Site itself -
Archive (you never know) -
4 posts omitted. Click reply to view.


IIRC they changed software after getting spammed to death. You can just download the archive from the second link since it's now read only anyway.


I guess they are, it's just sad that every time wikis are mentioned most people tend to believe they can only be collaborative encyclopedias.


okay, fair


ward cunningham, the author of c2, decided to redesign wiki concept couple of years ago. that was around the time when javascript was an exciting technology, but before everyone realized what a horrible idea it is. he calls the new version smallest federated wiki, you can google it up. there are some useful features there, but i think the result is less intuitive. i've been following his blog with one eye during the redesign, and i wouldn't be able to tell you what the new featureset is supposed to be. backend gives out json, front end renders it, and you can have embedded computation on backend? there's also better forking? i wouldn't say it was a particularly successful redesign, and it also robed c2 specifically of its old timey charm.


File: 1534961353176.jpg (497.45 KB, 2160x1920, c2.jpg)

File: 1533621027843.png (297.37 KB, 600x430, serial_experiments_lain_re….png)


Hi Alice, I made my first working website. It is a small imageboard, it actually has only 2 boards(General and nsfw). I'm, of course, open to any suggestion and advice, please help me! :)
It was fun making it
1 post omitted. Click reply to view.


I'm extremely sorry about that! I'll try to fix it, thanks for the feedback <3


What technology stack you have used in this project?
Can someone elaborate?


Warning: Constants may only evaluate to scalar values in /home/tinachan/public_html/settings.php on line 25

Warning: Constants may only evaluate to scalar values in /home/tinachan/public_html/settings.php on line 26

Warning: Constants may only evaluate to scalar values in /home/tinachan/public_html/inc/defines.php on line 17

Warning: Constants may only evaluate to scalar values in /home/tinachan/public_html/inc/defines.php on line 20

Notice: Use of undefined constant TINYIB_HIDEFIELDS - assumed 'TINYIB_HIDEFIELDS' in /home/tinachan/public_html/imgboard.php on line 90

Warning: in_array() expects parameter 2 to be array, string given in /home/tinachan/public_html/imgboard.php on line 93

Warning: in_array() expects parameter 2 to be array, string given in /home/tinachan/public_html/imgboard.php on line 97

Warning: in_array() expects parameter 2 to be array, string given in /home/tinachan/public_html/imgboard.php on line 100

Warning: in_array() expects parameter 2 to be array, string given in /home/tinachan/public_html/imgboard.php on line 103

Warning: in_array() expects parameter 2 to be array, string given in /home/tinachan/public_html/imgboard.php on line 118

Warning: in_array() expects parameter 2 to be array, string given in /home/tinachan/public_html/imgboard.php on line 168

That file is larger than 2 MB.




But did you actually fix the code or just disable the warnings?

File: 1533401418198.jpg (47.66 KB, 718x624, DGgtP0rXUAEJsoZ.jpg)


I want to learn Java programming at least the basic stuff ( OOP, Polymorphism, control flow ect..)Is it possible to do so in a months time for someone who has done a bit of programming but not too much; if so how would I go about doing it? What types of pdfs do I need, exercise sites ect..


File: 1533412346378.png (377.56 KB, 1450x1080, challenges.png)

I'd claim that "learning to program" takes years, but it should be fairly easy to pick up the basics in a month, especially if you already have some experience.

Is there some particular reason or project you want to learn programming for?

>What types of pdfs do I need, exercise sites ect..

Unfortunately I can't recommenced any specific resource - the book I learned Java from is massively out-of-date now.
As for exercises - problems that a directly relevant to you will always be the most interesting. For example: tools to interact with image boards. Failing that, it's pretty easy to find lists of small example problems online.


I am not really looking to do much just to refresh myself with the material as I have taken Java 1 my freshman year in college and have spent the last year and a half or so finishing up my gen eds and math/physics stuff making me forget a lot of the material.


In that case I would just quickly go through the official Java tutorials from Oracle, or at least the ones that seem relevant to you, and then do some exercises.


You could try HackerRank or CodeWars. Find some java reference book and do the exercises, contests, challenges, etc.

File: 1527513472465.jpg (148.45 KB, 1280x720, aki-book.jpg)


I have to debug a lot, most often code that I didn't write. But the problem is, I'm not very good at it. Is it possible to specifically train for it? Or is there some common methodology to it? Maybe some tips and tricks?

Also if you have or know any good stories about debugging, I'd love to hear them!
9 posts and 1 image reply omitted. Click reply to view.



Another dimension here is when you just straight up don't have enough information to create a reproducer. Then you're reduced to jiggling this, poking that, trying this other thing, and thinking very hard about exactly what the system would have to do in order to behave in the way the person reporting the bug is describing. Succeeding under those sorts of circumstances feels pretty heroic.


Do you think using techniques from mutation testing to randomly seed a program with bugs and then debugging those would be a valuable exercise or is it a waste of time?


I debug soykafty test cases written in C running on soykafty, broken hardware. I can at least tell you the basics:
- Make sure optimization is turned OFF (-O0)
- Make sure debugging support is turned on (-g3)
- Make sure you have the source code of the program (use the 'directory' command in gdb to add locations to search for the source code)
- use GDB's text user interface ('gdb -tui')
- When all else fails and your world is still not sane, a printf & a recompile can be the most reliable tool in your bag.


That seems like a waste of time. The kinds of bugs a mutation testing program will generate probably arn't the kinds of bugs that would provide useful debugging experience. Why not fix real bugs?


I don't know any project that could use my help.

File: 1533348417703.png (Spoiler Image, 467.85 KB, 750x1334, IMG_6870.PNG)







File: 1533247668884.png (1.01 MB, 1702x2471, 1530328878498.png)


I'm not really into security but i need to crack a wpa2
But i can't find a good wordlist in my native lenguage.
I have some ideas to make my oun but i can't find a tutorial or a book that helps me.
I feel confortable whith C# and java.
Any suggestions?


can't you just get some sample texts, filter punctuation and standardize capitalization, and then basically have your list?


You could try scraping Wiktionary or extract it from a spell-checker program.


>crack a wpa2
don't. unless you have a very good wordlist or you really know how people in your region generate their password it is pointless (bruteforce is pointless unless the target range is pretty small or you have a super computer). most people even use random generated default router passwords, which is a no go. use alternative attack methods that target wps instead (e.g. pixie dust).


>you really know how people in your region generate their password
Well, at least i think i know.


then learn how2hashcat. your problem is not directly related to wpa2 but actually hash cracking in general. learn stuff like how to write rules for word generation etc.

File: 1497467099226.png (14.21 KB, 246x614, scr.PNG)


Have you ever coded a malware ? ,
-if yes what language you used ;
-if no why not ?
33 posts and 4 image replies omitted. Click reply to view.




pls, just use tor you could tell us all the details if they were.


Don't believe everything someone writes on the internet. If it really was that big, he would mind 100% OPSEC and never would mention details like he already did. Or he is completely dumb.


I agree with this.
I bet he is just a LARPing script kiddie.


left around some flash drives which autobooted a vbscript to change all system sounds to a stereotypical clown nose honk, back in college

100% worth it when I finally heard one go off in the wild

File: 1493993896426.png (17.73 KB, 560x560, github.png)


33 posts and 2 image replies omitted. Click reply to view.


Are there any Arisu projects that need contributors?


Normally I love to deal with low-level C work, but recently I have been writing some rulesets for HTTPS Everywhere. It is funny how many sites don't give a soykaf about cookies or HTTPS, soykaf is insecure and nobody gives a fuck about it lol. Just discovered a .gov site which uses HTTP for login page and only uses a soykafty PHPSESSID for session verification (no additional IP, user-agent checks or whatever).


Probably. It would be nice if there were a directory of projects that exist in and around the community. What I know of are these:


Hey. Im new in C language and i want improve my skill. Does lainons know some project which can give some simple task?


If by new you mean you've never made anything, probably not. Try porting some small utility.

File: 1529427554416.png (160.95 KB, 900x630, memo.png)


What would you say are the basics of programming. What would one need to know to be a programmer. I am learning C and looking for some guidence.
30 posts and 12 image replies omitted. Click reply to view.


••• SImple Note •••

1. learning programming is NOT related to language ( there are common thing between langs) but every language has it's own feature and you will learn more and more
consider Programming Languages {A, B, C} courses which tries to make you learn about languase and how easly to move around them by learn concepts of languages.


All your answer is incorrect
You just need to Believe in God
The rest will come


If you want to understand computers, I recommend the book "CODE - The Hidden Language of Software and Hardware" by Charles Petzold. Learning C will not really tell you how Computers work, and I'm quite certain you would agree after reading said book.


That is I think a valid solution to >1254's prompt, that is, the final two lines are a valid solution, the rest is cruft.


>Learning C will not really tell you how Computers work
computers are many layered machines.
if you only study one layer, i'm quite certain you will overestimate it's importance.

Delete Post [ ]
[1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12]
[ Catalog ]