[ a / b / cf / cy / g / lain ] [ fresh / meta ] [ home / rules / faq / affiliates ]

/g/ - Technology

Programming and Electronics
Password (For file deletion.)

Hop in to our IRC channel! #wirechan@rizon.net

File: 1588104661337.jpg (1.15 MB, 1000x1415, 42038e231e75cf95c7028cd5f6….jpg)


Let's collect here programming books that are unusual in some sense, be it their approach, presentation, or simply just quality.


File: 1588105017883-0.png (508.75 KB, 674x881, The_Little_Schemer_4th_2.png)

File: 1588105017883-1.png (106.59 KB, 640x833, example.png)

The Little Schemer (and its continuations) have a very nice dialogue-like structure to them, which takes a bit of practice to read effectively, but once you are used to it, is a delight to read. The examples it use are very fun, too. I was told that it is an example of "programmed instruction" but other books labelled programmed instruction are nowhere near this masterpiece.


File: 1588105789691.jpg (34.29 KB, 386x500, Functional C.jpg)

This is a textbook written for students whose introductory programming class used a functional programming language, the concrete examples are in SML. It teaches C and imperative programming through translating functional programs into efficient and idiomatic C programs. Sometimes the translations are quite formal, other times somewhat heuristic.

File: 1585668103947.jpg (165.16 KB, 1280x720, mpv-shot1289.jpg)



You can download any paper from ACM for free, until June 30, 2020! Quickly grab what you couldn't even find on sci-hub!

Don't know what to read? The Computing Surveys journal is full of papers that give an overview to the state of the art in many topics, it's always a good way to discover new problems, challenges and solutions: https://dl.acm.org/journal/csur

Happy learning!


Yo, there’s also Library Genesis for textbook PDFs. It’s fucking great.

File: 1520648129111.png (459.91 KB, 1080x1080, Cute_Fish_Fauna.png)


Have you heard of Hy?
It's Lisp that works like Python.
You can access Python libraries even.
What do you think of it?
6 posts and 3 image replies omitted. Click reply to view.


File: 1583185535370.png (684.46 KB, 600x890, 4202798.png)

>Is the format even the same for CPython, PyPy and other Python interpreters? Sorry for the questions, I have no idea how it works.
"""Python source code is compiled into bytecode, the internal representation of a Python program in the CPython interpreter. The bytecode is also cached in .pyc files so that executing the same file is faster the second time (recompilation from source to bytecode can be avoided). This “intermediate language” is said to run on a virtual machine that executes the machine code corresponding to each bytecode. Do note that bytecodes are not expected to work between different Python virtual machines, nor to be stable between Python releases.

A list of bytecode instructions can be found in the documentation for the dis module."""

"""The dis module supports the analysis of CPython bytecode by disassembling it. The CPython bytecode which this module takes as an input is defined in the file Include/opcode.h and used by the compiler and the interpreter.

CPython implementation detail: Bytecode is an implementation detail of the CPython interpreter. No guarantees are made that bytecode will not be added, removed, or changed between versions of Python. Use of this module should not be considered to work across Python VMs or Python releases."""

>I was hoping for something more detailed



File: 1583186946524.jpg (312.76 KB, 2048x1739, 9ceab00eb6aa52da64d7584f5c….jpg)

Looks like I just need to RTFM. Do they somewhere also explain why they decided to keep the bytecode implementation defined?


File: 1583201092528.jpg (746.8 KB, 1280x1920, 3241784.jpg)

I'm not aware of a direct statement of the rationale behind that decision – it's not in e.g. the Design and History FAQ [0]. The spirit of The Python Language Reference suggests that it was specified in terms of an abstract execution model [1] precisely to allow more freedom for Alternate Implementations [2].

[0] https://docs.python.org/3/faq/design.html
[1] https://docs.python.org/3/reference/executionmodel.html
[2] https://docs.python.org/3/reference/introduction.html#alternate-implementations


When running a python program, the following steps are taken:
Python source code -> abstract syntax tree (AST) -> bytecode
Hy replaces the "Python source code -> AST" step.

We should note that bytecode is an implementation detail.
CPython has its own format, Jython compiles to JRE bytecode, and other implementations can use more complicated means such as running and compiling simultaneously (JIT compilation).

>Maybe they do it like this because there's no portable bytecode format?
It's simpler if you just replace the "source code -> AST" step.
AST is the ideal model to compile your code to
because it is the same level of abstraction as it's input (source code).
You can easily see create and run your own AST with python's ast library.
It's pretty trivial to even implement a simple language yourself using that library.


File: 1583868798991.jpeg (117.25 KB, 929x1245, 9922a90984ae75be.jpeg)

Doesn't it make a lot of optimizations impossible to do? Since you are basically translating your semantics into sugar-free Python.

File: 1582356754580.jpg (39.73 KB, 500x352, 1576393747453-0.jpg)


Does anyone have a link for the source code of the Antidepressant CSS theme?


File: 1523256594186.jpg (38.14 KB, 400x527, surf-the-web.jpg)


What browsers do you guys use to surf the web?
I use firefox developer edition so i can install my won addons.

What other tools do you use to get around the net?
31 posts and 3 image replies omitted. Click reply to view.


No, have you?


I haven't yet. But I may decide to give it a try in the next day or two. More or less have been curious about it in the meanwhile.




I'm still happy with Firefox. There's some minor nuisances, but overall I find it pretty good.


Same, I'm happy with Firefox for the most part. But I am interested in trying something new. I'd like to eventually replace it with something a lot better for my overall needs.

File: 1579825861259.jpg (15.18 KB, 400x300, vr.jpg)


I wanted to make a somewhat niche imageboard but my friend dropped out of the developing due to depression and i am more of an idea/design/admin kinda of person than good programmer and it ended up being more work that i can handle, i've been admin/mod for forums back in the day but never really the coding guy so we kinda just shot down the domain.

Has any of you operated something like that? Or has a cool webspace? or want to do one with me


Have you thought of joining wirechan maybe?


wirechan is in pretty good shape alreadythey got everything on point for the theme they're going for i think, i just wanted to make a image/textboard in a different theme that is not very popular with imageboard users, it was just an idea that i threw out with my friend and he said he would be down to make it but i wasn't supposed to be i guess.

Do you have a cool webspace fren?


Yeah, I have a small landing page for my ZNC and that stuff, plus my friends are working on a revival for an ib they had, plus another one has his own ib and I help them moderate it.

File: 1531967125232.jpg (331.64 KB, 1283x1216, pro_micro_pinout_v1_0_blue.jpg)


*AAAaargh why doesn't it work on the lcd display channel with this board lol
2 posts and 1 image reply omitted. Click reply to view.


It's working on the breadboard now =D

Kind of an odd solution, but dropping the clock rate back down to 8Mhz with xdiv=0x01, same as the nano got results

void nnn_ILI9341::clock_modifier(uint8_t xdiv){
CLKPR = 1<<7;
CLKPR = xdiv & 0x0F;


Well, it worked for a bit on the breadboard, loose connections(?) permitting

Still no luck with the harness / display out, though it's reading the touch input over spi just fine


Started making a second harness using solid-core jumper-wires, display tested okay on usb power prior to wiring in the touch interface, but now again doesn't want to work

Also with both harnesses display and touch works when the micro is powered directly from a couple of AA batteries, as an anon mentioned elsewhere


More tests, 2xAA through a little voltage step-up chip for 5 volts, 32u4 / harness 2
Display is working

Tried to repeat display working without touch connected using jumpers, usb connected / fail?

It really doesn't want to work on the 32u4/pro micro with usb connection for some reason


use a scope

File: 1516477938977.png (12.83 KB, 256x256, ClipboardImage.png)


Good morning, evening and night, /g/. I'd like to talk to you about a pretty popular but lacking and somewhat horrible distro that you're all aware of; Arch GNU/Linux.
11 posts and 2 image replies omitted. Click reply to view.


if only I did


File: 1552982047204.png (79.57 KB, 472x353, hamis.png)



Cool people use Arch with OpenRC.


I've got Void with runit on my laptop right now, pretty good so far.


no cool person uses Arch, stop spreading lies

Delete Post [ ]
[1] [2] [3] [4] Next | Catalog
[ a / b / cf / cy / g / lain ] [ fresh / meta ] [ home / rules / faq / affiliates ]