並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 72件

新着順 人気順

syntax for nested if in pythonの検索結果1 - 40 件 / 72件

  • The Prompt Engineering Playbook for Programmers

    Developers are increasingly relying on AI coding assistants to accelerate our daily workflows. These tools can autocomplete functions, suggest bug fixes, and even generate entire modules or MVPs. Yet, as many of us have learned, the quality of the AI’s output depends largely on the quality of the prompt you provide. In other words, prompt engineering has become an essential skill. A poorly phrased

      The Prompt Engineering Playbook for Programmers
    • GitHub - modelcontextprotocol/servers: Model Context Protocol Servers

      Official integrations are maintained by companies building production ready MCP servers for their platforms. 21st.dev Magic - Create crafted UI components inspired by the best 21st.dev design engineers. ActionKit by Paragon - Connect to 130+ SaaS integrations (e.g. Slack, Salesforce, Gmail) with Paragon’s ActionKit API. Adfin - The only platform you need to get paid - all payments in one place, in

        GitHub - modelcontextprotocol/servers: Model Context Protocol Servers
      • research!rsc: Coroutines for Go

        This post is about why we need a coroutine package for Go, and what it would look like. But first, what are coroutines? Every programmer today is familiar with function calls (subroutines): F calls G, which stops F and runs G. G does its work, potentially calling and waiting for other functions, and eventually returns. When G returns, G is gone and F continues running. In this pattern, only one fu

        • Writing a C compiler in 500 lines of Python

          A few months ago, I set myself the challenge of writing a C compiler in 500 lines of Python1, after writing my SDF donut post. How hard could it be? The answer was, pretty hard, even when dropping quite a few features. But it was also pretty interesting, and the result is surprisingly functional and not too hard to understand! There's too much code for me to comprehensively cover in a single blog

          • Your URL Is Your State

            Couple of weeks ago when I was publishing The Hidden Cost of URL Design I needed to add SQL syntax highlighting. I headed to PrismJS website trying to remember if it should be added as a plugin or what. I was overwhelmed with the amount of options in the download page so I headed back to my code. I checked the file for PrismJS and at the top of the file, I found a comment containing a URL: /* http

            • Moving off of TypeScript

              We Love You, TypeScriptFor nearly five years now, Motion has operated in a large TypeScript monorepo. At its peak, it was roughly ~2.5 million lines of code after excluding comments, node_modules, etc. To manage this, we used Vercel’s rather excellent Turborepo build system. This is not a blog post hating on TypeScript — quite the opposite! Motion would likely not even have survived until today wi

                Moving off of TypeScript
              • Lessons from Writing a Compiler

                The prototypical compilers textbook is: 600 pages on parsing theory. Three pages of type-checking a first-order type system like C. Zero pages on storing and checking the correctness of declarations (the “symbol table”). Zero pages on the compilation model, and efficiently implementing separate compilation. 450 pages on optimization and code generation. The standard academic literature is most use

                • Announcing .NET 10 - .NET Blog

                  Today, we are excited to announce the launch of .NET 10, the most productive, modern, secure, intelligent, and performant release of .NET yet. It’s the result of another year of effort from thousands of developers around the world. This release includes thousands of performance, security, and functional improvements across the entire .NET stack-from languages and developer tools to workloads-enabl

                    Announcing .NET 10 - .NET Blog
                  • Prototyping in Rust | corrode Rust Consulting

                    Programming is an iterative process - as much as we would like to come up with the perfect solution from the start, it rarely works that way. Good programs often start as quick prototypes. The bad ones stay prototypes, but the best ones evolve into production code. Whether you’re writing games, CLI tools, or designing library APIs, prototyping helps tremendously in finding the best approach before

                      Prototyping in Rust | corrode Rust Consulting
                    • Wvlet: Redesigning 50-Year-Old SQL for Modern Data Analytics | Wvlet

                      We are excited to announce the release of Wvlet version 2024.9, an open-source flow-style query language designed to help users to write efficient queries for SQL engines. You can try Wvlet, pronounced as weave-let, directly in your web browser at Wvlet Playground. The source code of Wvlet compiler is available at GitHub wvlet/wvlet. Why Wvlet?​ At Treasure Data, we process over 3 million SQL quer

                        Wvlet: Redesigning 50-Year-Old SQL for Modern Data Analytics | Wvlet
                      • The yaml document from hell

                        written by Ruud van Asseldonk published 11 January 2023 For a data format, yaml is extremely complicated. It aims to be a human-friendly format, but in striving for that it introduces so much complexity, that I would argue it achieves the opposite result. Yaml is full of footguns and its friendliness is deceptive. In this post I want to demonstrate this through an example. This post is a rant, and

                        • March 2025 (version 1.99)

                          Update 1.99.1: The update addresses these security issues. Update 1.99.2: The update addresses these issues. Update 1.99.3: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the March 2025 release of Visual Studio Code. There are many updates in this version that we hope you'll like, some of the key highligh

                            March 2025 (version 1.99)
                          • Weird Lexical Syntax

                            I just learned 42 programming languages this month to build a new syntax highlighter for llamafile. I feel like I'm up to my eyeballs in programming languages right now. Now that it's halloween, I thought I'd share some of the spookiest most surprising syntax I've seen. The languages I decided to support are Ada, Assembly, BASIC, C, C#, C++, COBOL, CSS, D, FORTH, FORTRAN, Go, Haskell, HTML, Java,

                              Weird Lexical Syntax
                            • Golang Mini Reference 2022: A Quick Guide to the Modern Go Programming Language (REVIEW COPY)

                              Golang Mini Reference 2022 A Quick Guide to the Modern Go Programming Language (REVIEW COPY) Harry Yoon Version 0.9.0, 2022-08-24 REVIEW COPY This is review copy, not to be shared or distributed to others. Please forward any feedback or comments to the author. • feedback@codingbookspress.com The book is tentatively scheduled to be published on September 14th, 2022. We hope that when the release da

                              • AST vs. Bytecode: Interpreters in the Age of Meta-Compilation

                                233 AST vs. Bytecode: Interpreters in the Age of Meta-Compilation OCTAVE LAROSE, University of Kent, UK SOPHIE KALEBA, University of Kent, UK HUMPHREY BURCHELL, University of Kent, UK STEFAN MARR, University of Kent, UK Thanks to partial evaluation and meta-tracing, it became practical to build language implementations that reach state-of-the-art peak performance by implementing only an interprete

                                • April 2022 (version 1.67)

                                  Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Update 1.67.1: The update addresses this security issue. Update 1.67.2: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the April 2022 release of Visual Studio Code. There are many updates in this version that we hope

                                    April 2022 (version 1.67)
                                  • Parsing SQL - Strumenta

                                    The code for this tutorial is on GitHub: parsing-sql SQL is a language to handle data in a relational database. If you worked with data you have probably worked with SQL. In this article we will talk about parsing SQL. It is in the same league of HTML: maybe you never learned it formally but you kind of know how to use it. That is great because if you know SQL, you know how to handle data. However

                                      Parsing SQL - Strumenta
                                    • Recto — a truly 2D language

                                      Masato Hagiwara Open in Recto Pad Google Colab Github Recto Pad TL;DR Recto is a 2D programming language that uses nested rectangles as its core syntax, encoding structure and recursion directly in space instead of a linear stream of text. Recto explores new ways to write, parse, and reason about code—and even natural language—spatially. Introduction Open in Recto Pad Virtually all the languages w

                                        Recto — a truly 2D language
                                      • Kalyn: a self-hosting compiler for x86-64

                                        Over the course of my Spring 2020 semester at Harvey Mudd College, I developed a self-hosting compiler entirely from scratch. This article walks through many interesting parts of the project. It’s laid out so you can just read from beginning to end, but if you’re more interested in a particular topic, feel free to jump there. Or, take a look at the project on GitHub. Table of contents What the pro

                                        • Zig, Rust, and other languages | notes.eatonphil.com

                                          Having worked a bit in Zig, Rust, Go and now C, I think there are a few common topics worth having a fresh conversation on: automatic memory management, the standard library, and explicit allocation. Zig is not a mature language. But it has made enough useful choices for a number of companies to invest in it and run it in production. The useful choices make Zig worth talking about. Go and Rust are

                                          • Wasm core dumps and debugging Rust in Cloudflare Workers

                                            Wasm core dumps and debugging Rust in Cloudflare Workers2023-08-14 A clear sign of maturing for any new programming language or environment is how easy and efficient debugging them is. Programming, like any other complex task, involves various challenges and potential pitfalls. Logic errors, off-by-ones, null pointer dereferences, and memory leaks are some examples of things that can make software

                                              Wasm core dumps and debugging Rust in Cloudflare Workers
                                            • Lean for JavaScript Developers — overreacted

                                              Lean for JavaScript DevelopersSeptember 2, 2025 This is my opinionated syntax primer for the Lean programming language. It is far from complete and may contain inaccuracies (I’m still learning Lean myself) but this is how I wish I was introduced to it, and what I wish was clarified. Why Lean? This post assumes you’re already eager to learn a bit of Lean. For motivation, I humbly submit to you two

                                                Lean for JavaScript Developers — overreacted
                                              • The Koka programming language

                                                Statically typed programming languages can help catch mismatches between the kinds of values a program is intended to manipulate, and the values it actually manipulates. While there have been many bytes spent on discussions of whether this is worth the effort, some programming language designers believe that the type checking in current languages does not go far enough. Koka, an experimental funct

                                                • March 2022 (version 1.66)

                                                  Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Update 1.66.1: The update addresses these issues. Update 1.66.2: The update addresses these security issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the March 2022 release of Visual Studio Code. There are many updates in this version that we ho

                                                    March 2022 (version 1.66)
                                                  • The KDL Document Language

                                                    KDL is a small, pleasing document language with xml-like semantics that looks like you're invoking a bunch of CLI commands! It's meant to be used both as a serialization format and a configuration language, much like JSON, YAML, or XML. It looks like this: package { name "my-pkg" version "1.2.3" dependencies { // Nodes can have standalone values as well as // key/value pairs. lodash "^3.2.1" optio

                                                    • Vimmer が紹介する「いぶし銀」なプラグインまとめ(後編)

                                                      この記事は Vim 駅伝 の 08/21 の記事です。 前回の記事は kyoh86 さんによる、 08/18 の「ddu.vimの基本設定概観」という記事でした。 次回は 08/23 に投稿される予定です。 はじめに 本記事は、いぶし銀プラグイン企画の結果発表の後編です。 Vimmer が実際に普段の編集を行う上で、なくてはならないと感じるプラグインを紹介していきます。前編は以下の記事を参照してください。 後編では、94件の回答のうち前編で紹介しなかったもの全てを紹介します。 全部で52個もあるため、プラグインの大まかな分類ごとに分けて紹介しています。一度に全て読むのは大変ですから、「目次」から気になるカテゴリを選んで読み進めることをおすすめします。 紹介フォーマット 前編の記事同様、各プラグインには以下の項目を設けています。 プラグイン名 プラグインへのリンク 概要 (一応)紹介記事なの

                                                        Vimmer が紹介する「いぶし銀」なプラグインまとめ(後編)
                                                      • Maestro: Netflix’s Workflow Orchestrator

                                                        By Jun He, Natallia Dzenisenka, Praneeth Yenugutala, Yingyi Zhang, and Anjali Norwood TL;DRWe are thrilled to announce that the Maestro source code is now open to the public! Please visit the Maestro GitHub repository to get started. If you find it useful, please give us a star. What is MaestroMaestro is a horizontally scalable workflow orchestrator designed to manage large-scale Data/ML workflows

                                                          Maestro: Netflix’s Workflow Orchestrator
                                                        • A Lisp Interpreter Implemented in Conway’s Game of Life

                                                          Lisp in Life is a Lisp interpreter implemented in Conway’s Game of Life. The entire pattern is viewable on the browser here. To the best of my knowledge, this is the first time a high-level programming language was interpreted in Conway’s Game of Life. Running Lisp on the Game of Life Lisp is a language with a simple and elegant design, having an extensive ability to express sophisticated ideas as

                                                            A Lisp Interpreter Implemented in Conway’s Game of Life
                                                          • 0.10.0 Release Notes ⚡ The Zig Programming Language

                                                            Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                                                            • Blogged Answers: My Experience Modernizing Packages to ESM

                                                              Random musings on React, Redux, and more, by Redux maintainer Mark "acemarke" Erikson This is a post in the Blogged Answers series. Details on the painful experiences and hard-earned lessons I've learned migrating the Redux packages to ESM Table of Contents 🔗︎ Introduction Redux Packages Background Packages and Configurations Issue History Early Attempts Migrating to Vitest Initial Alpha Testing

                                                                Blogged Answers: My Experience Modernizing Packages to ESM
                                                              • Accelerate Python code 100x by import taichi as ti | Taichi Docs

                                                                Python has become the most popular language in many rapidly evolving sectors, such as deep learning and data sciences. Yet its easy readability comes at the cost of performance. Of course, we all complain about program performance from time to time, and Python should certainly not take all the blame. Still, it's fair to say that Python's nature as an interpreted language does not help, especially

                                                                • Writing GNOME Apps with Swift

                                                                  Swift is well-suited for creating user interfaces thanks to the clean syntax, static typing, and special features making code easier to write. Result builders, combined with Swift’s closure expression syntax, can significantly enhance code readability. Adwaita for Swift leverages these Swift features to provide an intuitive interface for developing applications for the GNOME platform. GNOME is a p

                                                                    Writing GNOME Apps with Swift
                                                                  • Let's Write a Tree-Sitter Major Mode

                                                                    Let’s Write a Tree-Sitter Major Mode Creating a standard programming major mode presents significant challenges, with the intricate tasks of establishing proper indentation and font highlighting being among the two hardest things to get right. It's painstaking work, and it'll quickly descend into a brawl between the font lock engine and your desire for correctness. Tree-sitter makes writing many m

                                                                      Let's Write a Tree-Sitter Major Mode
                                                                    • Announcing DuckDB 1.3.0

                                                                      To install the new version, please visit the installation guide. Note that it can take a few hours to days to release some client libraries (e.g., Go, R, Java) and extensions (e.g., the UI) due to the extra changes and review rounds required. We are proud to release DuckDB 1.3.0. This release of DuckDB is named “Ossivalis” after Bucephala Ossivalis, an ancestor of the Goldeneye duck that lived mil

                                                                        Announcing DuckDB 1.3.0
                                                                      • PEP 8 – Style Guide for Python Code | peps.python.org

                                                                        PEP 8 – Style Guide for Python Code Author: Guido van Rossum <guido at python.org>, Barry Warsaw <barry at python.org>, Alyssa Coghlan <ncoghlan at gmail.com> Status: Active Type: Process Created: 05-Jul-2001 Post-History: 05-Jul-2001, 01-Aug-2013 Table of Contents Introduction A Foolish Consistency is the Hobgoblin of Little Minds Code Lay-out Indentation Tabs or Spaces? Maximum Line Length Shoul

                                                                          PEP 8 – Style Guide for Python Code | peps.python.org
                                                                        • What's New in Emacs 28.1?

                                                                          Try Mastering Emacs for free! Are you struggling with the basics? Have you mastered movement and editing yet? When you have read Mastering Emacs you will understand Emacs. It’s that time again: there’s a new major version of Emacs and, with it, a treasure trove of new features and changes. Notable features include the formal inclusion of native compilation, a technique that will greatly speed up y

                                                                          • Type Parameters Proposal

                                                                            Ian Lance Taylor Robert Griesemer August 20, 2021 StatusThis is the design for adding generic programming using type parameters to the Go language. This design has been proposed and accepted as a future language change. We currently expect that this change will be available in the Go 1.18 release in early 2022. AbstractWe suggest extending the Go language to add optional type parameters to type an

                                                                            • PEP 634 – Structural Pattern Matching: Specification | peps.python.org

                                                                              PEP 634 – Structural Pattern Matching: Specification Author: Brandt Bucher <brandt at python.org>, Guido van Rossum <guido at python.org> BDFL-Delegate: Discussions-To: Python-Dev list Status: Final Type: Standards Track Created: 12-Sep-2020 Python-Version: 3.10 Post-History: 22-Oct-2020, 08-Feb-2021 Replaces: 622 Resolution: Python-Committers message Table of Contents Abstract Syntax and Semantic

                                                                                PEP 634 – Structural Pattern Matching: Specification | peps.python.org
                                                                              • Databases in 2023: A Year in Review

                                                                                I am starting this new year the same way I ended the last: taking antibiotics because my biological daughter brought home a nasty sinus bug from Carnegie Mellon’s preschool. This was after my first wife betrayed me and gave me COVID. Nevertheless, it is time for my annual screed on last year’s major database happenings and trends since a lot has happened. My goal is to keep my trenchant opinions f

                                                                                  Databases in 2023: A Year in Review
                                                                                • 12 Languages in 12 Months

                                                                                  I stumbled across Exercism last year and was immediately charmed. It's a website devoted to teaching programming languages. It's got a great UI, offers free mentoring (by a human!), and is entirely open source. Last January, they announced a new program called 12in23, where they challenged participants to try 12 new programming languages in 2023. Each month would have a theme (such as "Analytical

                                                                                    12 Languages in 12 Months