frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

NewASM Virtual Machine

https://github.com/bracesoftware/newasm
1•DEntisT_•26s ago•0 comments

Terminal-Bench 2.0 Leaderboard

https://www.tbench.ai/leaderboard/terminal-bench/2.0
1•tosh•49s ago•0 comments

I vibe coded a BBS bank with a real working ledger

https://mini-ledger.exe.xyz/
1•simonvc•1m ago•1 comments

The Path to Mojo 1.0

https://www.modular.com/blog/the-path-to-mojo-1-0
1•tosh•3m ago•0 comments

Show HN: I'm 75, building an OSS Virtual Protest Protocol for digital activism

https://github.com/voice-of-japan/Virtual-Protest-Protocol/blob/main/README.md
3•sakanakana00•7m ago•0 comments

Show HN: I built Divvy to split restaurant bills from a photo

https://divvyai.app/
3•pieterdy•9m ago•0 comments

Hot Reloading in Rust? Subsecond and Dioxus to the Rescue

https://codethoughts.io/posts/2026-02-07-rust-hot-reloading/
3•Tehnix•10m ago•1 comments

Skim – vibe review your PRs

https://github.com/Haizzz/skim
2•haizzz•11m ago•1 comments

Show HN: Open-source AI assistant for interview reasoning

https://github.com/evinjohnn/natively-cluely-ai-assistant
3•Nive11•11m ago•4 comments

Tech Edge: A Living Playbook for America's Technology Long Game

https://csis-website-prod.s3.amazonaws.com/s3fs-public/2026-01/260120_EST_Tech_Edge_0.pdf?Version...
2•hunglee2•15m ago•0 comments

Golden Cross vs. Death Cross: Crypto Trading Guide

https://chartscout.io/golden-cross-vs-death-cross-crypto-trading-guide
2•chartscout•18m ago•0 comments

Hoot: Scheme on WebAssembly

https://www.spritely.institute/hoot/
3•AlexeyBrin•20m ago•0 comments

What the longevity experts don't tell you

https://machielreyneke.com/blog/longevity-lessons/
2•machielrey•22m ago•1 comments

Monzo wrongly denied refunds to fraud and scam victims

https://www.theguardian.com/money/2026/feb/07/monzo-natwest-hsbc-refunds-fraud-scam-fos-ombudsman
3•tablets•26m ago•0 comments

They were drawn to Korea with dreams of K-pop stardom – but then let down

https://www.bbc.com/news/articles/cvgnq9rwyqno
2•breve•29m ago•0 comments

Show HN: AI-Powered Merchant Intelligence

https://nodee.co
1•jjkirsch•31m ago•0 comments

Bash parallel tasks and error handling

https://github.com/themattrix/bash-concurrent
2•pastage•31m ago•0 comments

Let's compile Quake like it's 1997

https://fabiensanglard.net/compile_like_1997/index.html
2•billiob•32m ago•0 comments

Reverse Engineering Medium.com's Editor: How Copy, Paste, and Images Work

https://app.writtte.com/read/gP0H6W5
2•birdculture•37m ago•0 comments

Go 1.22, SQLite, and Next.js: The "Boring" Back End

https://mohammedeabdelaziz.github.io/articles/go-next-pt-2
1•mohammede•43m ago•0 comments

Laibach the Whistleblowers [video]

https://www.youtube.com/watch?v=c6Mx2mxpaCY
1•KnuthIsGod•44m ago•1 comments

Slop News - The Front Page right now but it's only Slop

https://slop-news.pages.dev/slop-news
1•keepamovin•49m ago•1 comments

Economists vs. Technologists on AI

https://ideasindevelopment.substack.com/p/economists-vs-technologists-on-ai
1•econlmics•51m ago•0 comments

Life at the Edge

https://asadk.com/p/edge
4•tosh•57m ago•0 comments

RISC-V Vector Primer

https://github.com/simplex-micro/riscv-vector-primer/blob/main/index.md
4•oxxoxoxooo•1h ago•1 comments

Show HN: Invoxo – Invoicing with automatic EU VAT for cross-border services

2•InvoxoEU•1h ago•0 comments

A Tale of Two Standards, POSIX and Win32 (2005)

https://www.samba.org/samba/news/articles/low_point/tale_two_stds_os2.html
4•goranmoomin•1h ago•0 comments

Ask HN: Is the Downfall of SaaS Started?

4•throwaw12•1h ago•0 comments

Flirt: The Native Backend

https://blog.buenzli.dev/flirt-native-backend/
3•senekor•1h ago•0 comments

OpenAI's Latest Platform Targets Enterprise Customers

https://aibusiness.com/agentic-ai/openai-s-latest-platform-targets-enterprise-customers
2•myk-e•1h ago•0 comments
Open in hackernews

Algorithm Should Not Work

3•cyberborean•7mo ago
Below is a python program that performs an insertion sort. The main problem area is that "i" is changed within a loop the depends on i. This is very bad practice and will obviously lead to unexpected outcomes, but so far I have not been able to find an array that it does not work on. Can anyone figure out why it works?

def insertionSort(array): for i in range(1, len(array)): temp = array[i] tempPos = i-1 flag = False while flag == False and tempPos > -1: print(array) if temp < array[tempPos]: array[i] = array[tempPos] array[i-1] = temp tempPos = tempPos - 1 i = i - 1 else: flag = True

Comments

yorwba•7mo ago
Try stepping through it in a debugger and pay attention to the values of variables vs. what you think those values should be. Or make every second line be print(locals()) and read the trace.
not_your_vase•7mo ago

  >  The main problem area is that "i" is changed within a loop the depends on i. This is very bad practice and will obviously lead to unexpected outcomes
i's value doesn't persist between loops, it's a brand new i in every iteration of a for range loop. One loops modifications have no effect on the next loop. If it was c or a similar language's classic for-loop, then modifying the loop variable would be risky. But it is not the case here.
gus_massa•7mo ago
Remember to add two spaces to get the correct formating:

  def insertionSort(array):
    for i in range(1, len(array)):
      temp = array[i]
      tempPos = i-1
      flag = False
      while flag == False and tempPos > -1:
        print(array)
        if temp < array[tempPos]:
          array[i] = array[tempPos]
          array[i-1] = temp
          tempPos = tempPos - 1
          i = i - 1
        else:
          flag = True