
CommunityNews
A Perplexing Javascript Parsing Puzzle
What does this print?
x =1 x -->0 Think it through, then try it in a browser console! Answer and explanation in the dropdown.
Show answer
It prints 1.
wait wtf At the beginning of a line (and only at the beginning of a line), → starts a comment. The JavaScript is parsed as
x=1; x; // 0 The browser then displays the value of the last expression, which of course is 1.
Read in full here:
Popular General Dev topics

FUZIX
FUZIX is a fusion of various elements from the assorted UZI forks and
branches beaten together into some kind of semi-coherent pla...
New

TOKYO (Kyodo) – Japan’s government plans to encourage firms to let their employees choose to work four days a week instead of five, aimin...
New

Neovim nightly, v0.5.0 and v0.4.4 has been released.
Link: Release Nvim development (prerelease) build · neovim/neovim · GitHub
Link:...
New

It’s official. Your private communications can (and will) be spied on - European Digital Rights (EDRi).
On 6 July, the European Parliame...
New

Mediocre typing feel overshadows reliable wireless and fantastic battery life.
New

It has some interesting features:
It’s entirely wireless (the left half speaks Bluetooth to the right half, and the right half speaks B...
New

Building a Slack/Discord alternative with Tauri/Rust linen <span class="hashtag-icon-placeholder"></span>blog.
Introduction My name is K...
New

To avoid being replaced by LLMs, do what they can’t.
What LLM’s can’t do yet
New

Over the last decade, we’ve seen great advancements in distributed systems, but the way we program them has seen few fundamental improvem...
New

The new frameworks will continue until morale improves.
New
Other popular topics

I know that -t flag is used along with -i flag for getting an interactive shell. But I cannot digest what the man page for docker run com...
New

This looks like a stunning keycap set :orange_heart:
A LEGENDARY KEYBOARD LIVES ON
When you bought an Apple Macintosh computer in the e...
New

“Finding the Boundaries” Hero’s Journey with Noel Rappin @noelrappin
Even when you’re ultimately right about what the future ho...
New

Not sure if following fits exactly this thread, or if we should have a hobby thread…
For many years I’m designing and building model air...
New

I am asking for any distro that only has the bare-bones to be able to get a shell in the server and then just install the packages as we ...
New

If you are experiencing Rails console using 100% CPU on your dev machine, then updating your development and test gems might fix the issu...
New

The File System Access API with Origin Private File System.
WebKit supports new API that makes it possible for web apps to create, open,...
New

If you want a quick and easy way to block any website on your Mac using Little Snitch simply…
File > New Rule:
And select Deny, O...
New
New

Author Spotlight:
Bruce Tate
@redrapids
Programming languages always emerge out of need, and if that’s not always true, they’re defin...
New
Categories:
Sub Categories:
- All
- In The News
- Dev Chat (200)
- Questions (30)
- Resources (118)
- Blogs/Talks (26)
- Jobs (3)
- Events (14)
- Code Editors (58)
- Hardware (57)
- Reviews (4)
- Sales (15)
- Design & UX (4)
- Marketing & SEO (1)
- Industry & Culture (14)
- Ethics & Privacy (19)
- Business (4)
- Learning Methods (4)
- Content Creators (7)
- DevOps & Hosting (9)
Popular Portals
- /elixir
- /rust
- /wasm
- /ruby
- /erlang
- /phoenix
- /keyboards
- /rails
- /js
- /python
- /security
- /go
- /swift
- /vim
- /clojure
- /java
- /haskell
- /emacs
- /svelte
- /onivim
- /typescript
- /crystal
- /c-plus-plus
- /tailwind
- /kotlin
- /gleam
- /react
- /flutter
- /elm
- /ocaml
- /ash
- /opensuse
- /vscode
- /centos
- /php
- /deepseek
- /html
- /scala
- /zig
- /debian
- /nixos
- /lisp
- /agda
- /react-native
- /textmate
- /sublime-text
- /kubuntu
- /arch-linux
- /ubuntu
- /revery
- /django
- /manjaro
- /spring
- /diversity
- /nodejs
- /lua
- /c
- /slackware
- /julia
- /neovim