並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 50件

新着順 人気順

if else statement in java simple exampleの検索結果1 - 40 件 / 50件

  • Rewriting the Ruby parser

    At Shopify, we have spent the last year writing a new Ruby parser, which we’ve called YARP (Yet Another Ruby Parser). As of the date of this post, YARP can parse a semantically equivalent syntax tree to Ruby 3.3 on every Ruby file in Shopify’s main codebase, GitHub’s main codebase, CRuby, and the 100 most popular gems downloaded from rubygems.org. We recently got approval to merge this work into C

      Rewriting the Ruby parser
    • Python 3.13 gets a JIT

      Happy New Year everyone! In late December 2023 (Christmas Day to be precise), CPython core developer Brandt Bucher submitted a little pull-request to the Python 3.13 branch adding a JIT compiler. This change, once accepted would be one of the biggest changes to the CPython Interpreter since the Specializing Adaptive Interpreter added in Python 3.11 (which was also from Brandt along with Mark Shann

        Python 3.13 gets a JIT
      • 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

          • Announcing Dart 3

            Hello from Google I/O 2023. Today, live from Mountain View, we’re announcing Dart 3 — the largest Dart release to date! Dart 3 contains three major advancements. First, we’ve completed the journey to 100% sound null safety. Second, we’ve added major new language features for records, patterns, and class modifiers. Third, we’re giving a preview of the future, where we broaden our platform support w

              Announcing Dart 3
            • 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
              • Implementing Logic Programming

                Most of my readers are probably familiar with procedural programming, object-oriented programming (OOP), and functional programming (FP). The majority of top programming languages on all of the language popularity charts (like TIOBE) support all three to some extent. Even if a programmer avoided one or more of those three paradigms like the plague, they’re likely at least aware of them and what th

                  Implementing Logic Programming
                • 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

                  • The life and times of an Abstract Syntax Tree

                    You’ve reached computer programming nirvana. Your journey has led you down many paths, including believing that God wrote the universe in LISP, but now the truth is clear in your mind: every problem can be solved by writing one more compiler. It’s true. Even our soon-to-be artificially intelligent overlords are nothing but compilers, just as the legends foretold. That smart contract you’ve been wr

                      The life and times of an Abstract Syntax Tree
                    • The Go Programming Language and Environment – Communications of the ACM

                      Go is a programming language created at Google in late 2007 and released as open source in November 2009. Since then, it has operated as a public project, with contributions from thousands of individuals and dozens of companies. Go has become a popular language for building cloud infrastructure: Docker, a Linux container manager, and Kubernetes, a container deployment system, are core cloud techno

                      • Cloudflare functions with Scala.js

                        Indoor VivantsAnton Sviridov. I love reinventing the wheel and I usually use Scala for that. TL;DR We are deploying an app to Cloudflare using Scala.js We are using ScalablyTyped We are using Scala 3 heavily Code on Github Deployed app Cloudflare API bindings Welcome to the "Put ma Scala on yo cloud" series I want to say that I'm kicking off a blog series, but even I don't believe that. If I did,

                        • State of the Common Lisp ecosystem, 2020 🎉 - Lisp journey

                          NEW: 9 videos (86min) about CLOS on my Common Lisp course. Out of 7h+ of content. Rated 4.7/5. Learn more and stay tuned. 🎥 I also have cool Lisp showcases on Youtube . The last ones: how to build a web app in Common Lisp, part 1 and 2. This is a description of the Common Lisp ecosystem, as of January, 2021, from the perspective of a user and contributor. The purpose of this article is both to gi

                          • JEP 425: Virtual Threads (Preview)

                            Summary Introduce virtual threads to the Java Platform. Virtual threads are lightweight threads that dramatically reduce the effort of writing, maintaining, and observing high-throughput concurrent applications. This is a preview API. Goals Enable server applications written in the simple thread-per-request style to scale with near-optimal hardware utilization. Enable existing code that uses the j

                            • A guide to React design patterns - LogRocket Blog

                              Editor’s note: This guide to React design patterns was last reviewed for accuracy by Isaac Okoro on 12 April 2024. The article was also updated to add four more design patterns, covering prop combination, controlled components, forwardRefs, and conditional rendering. It was previously updated to include information about the render props pattern and state reducer pattern. Check out this article fo

                                A guide to React design patterns - LogRocket Blog
                              • Darker Corners of Go – Rytis Biel

                                Note: this article is available as an ebook and as a printed book for easier reading Introduction What is this? When I was first learning Go, I already knew several other programming languages. But after reading an introductory book and the language specification I felt like I really didn’t know enough about Go to use it for real world work. I felt I’d probably need to fall into many traps before

                                  Darker Corners of Go – Rytis Biel
                                • prompts.chat

                                  Welcome to the “Awesome ChatGPT Prompts” repository! While this collection was originally created for ChatGPT, these prompts work great with other AI models like Claude, Gemini, Hugging Face Chat, Llama, Mistral, and more. ChatGPT is a web interface created by OpenAI that provides access to their GPT (Generative Pre-trained Transformer) language models. The underlying models, like GPT-4o and GPT-o

                                  • V Language Review (2022)

                                    V is a programming language promising to be “Simple, fast, safe, compiled. For developing maintainable software.” V has a controversial past but what is the state of V in 2022? Is V worth checking out? In this post, we’ll take a look at V as it exists in May 2022. TLDR Read the summary Rules of engagement I’ll be using the current version of V built from git which is 50ab2cfd1ae02d4f4280f38c60b8db

                                    • HuggingFaceFW/fineweb · Datasets at Hugging Face

                                      "},"dump":{"kind":"string","value":"CC-MAIN-2013-20"},"url":{"kind":"string","value":"http://%20jwashington@ap.org/Content/Press-Release/2012/How-AP-reported-in-all-formats-from-tornado-stricken-regions"},"date":{"kind":"string","value":"2013-05-18T05:48:54Z"},"file_path":{"kind":"string","value":"s3://commoncrawl/crawl-data/CC-MAIN-2013-20/segments/1368696381249/warc/CC-MAIN-20130516092621-00000-

                                        HuggingFaceFW/fineweb · Datasets at Hugging Face
                                      • Sayonara, C++, and hello to Rust!

                                        This past May, I started a new job working in Rust. I was somewhat skeptical of Rust for a while, but it turns out, it really is all it’s cracked up to be. As a long-time C++ programmer, and C++ instructor, I am convinced that Rust is better than C++ in all of C++’s application space, that for any new programming project where C++ would make sense as the programming language, Rust would make more

                                        • Using a Framework will harm the maintenance of your software

                                          In this article I’m putting together my quotes, thoughts and notes on the idea that Frameworks harm the maintainability of the software you build in that framework. I’m proposing that Frameworks: are harming maintainability, but not deliberate. have different goals than you or your team. make trade-offs that harm maintainability of the projects built in them. are designed to take your project host

                                          • 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

                                              • Faster virtual machines: Speeding up programming language execution - Mort's Ramblings

                                                Date: 2023-01-15 Git: https://gitlab.com/mort96/blog/blob/published/content/00000-home/00015-fast-interpreters.md In this post, I hope to explore how interpreters are often implemented, what a "virtual machine" means in this context, and how to make them faster. Note: This post will contain a lot of C source code. Most of it is fairly simple C which should be easy to follow, but some familiarity w

                                                • https://cheats.rs/rust_cheat_sheet.pdf

                                                  Rust Language Cheat Sheet 26. August 2021 Contains clickable links to The Book , Rust by Example , Std Docs , Nomicon , Reference . Data Structures Data types and memory locations defined via keywords. Example Explanation struct S {} Define a struct with named fields. struct S { x: T } Define struct with named field x of type T. struct S ​(T); Define "tupled" struct with numbered field .0 of type

                                                  • Gregory Szorc's Digital Home | Rust is for Professionals

                                                    A professional programmer delivers value through the authoring and maintaining of software that solves problems. (There are other important ways for professional programmers to deliver value but this post is about programming.) Programmers rely on various tools to author software. Arguably the most important and consequential choice of tool is the programming language. In this post, I will articul

                                                    • Cloud9 で SAM を利用し AWS サービス毎の請求額を毎日 Slack に通知する | DevelopersIO

                                                      Cloud9 を利用して AWS のサービス毎の料金を毎日 Slack に通知する仕組みを作成しました。 コーヒーが好きな emi です。 AWSサービス毎の請求額を毎日 Slack に通知するため、以下のブログ AWSサービス毎の請求額を毎日Slackに通知してみた を見ながら設定しようとしたのですが、手元の Windows 11 端末に AWS CLI、AWS SAM CLI、Python などの開発環境を整えるのが面倒…!!と思いました。 そこで、AWS Cloud9 を使って手軽に一時的な開発環境を構築し、AWS Serverless Application Model (SAM) でサーバレス通知システムを構築しました。 AWS Serverless Application Model (SAM) とは AWS SAM は、サーバーレスアプリケーション構築用のオープンソースフレー

                                                        Cloud9 で SAM を利用し AWS サービス毎の請求額を毎日 Slack に通知する | DevelopersIO
                                                      • Rust in Perspective

                                                        We are discussing and working toward adding the language Rust as a second implementation language in the Linux kernel. A year ago Jake Edge made an excellent summary of the discussions so far on Rust for the Linux kernel and we (or rather Miguel and Wedson) have made further progress since then. For the record I think this is overall a good idea and worth a try. I wanted to add some background tha

                                                          Rust in Perspective
                                                        • How to maintain engineering velocity as you scale | Y Combinator

                                                          Engineering is typically the function that grows fastest at a scaling startup. It requires a lot of attention to make sure the pace of execution does not slow and cultural issues do not emerge as you scale. We’ve learned a lot about pace of execution in the past five years at Faire. When we launched in 2017, we were a team of five engineers. From the beginning, we built a simple but solid foundati

                                                            How to maintain engineering velocity as you scale | Y Combinator
                                                          • cuneicode, and the Future of Text in C

                                                            Following up from the last post, there is a lot more we need to cover. This was intended to be the post where we talk exclusively about benchmarks and numbers. But, I have unfortunately been perfectly taunted and status-locked, like a monster whose “aggro” was pulled by a tank. The reason, of course, is due to a few folks taking issue with my outright dismissal of the C and C++ APIs (and not showi

                                                              cuneicode, and the Future of Text in C
                                                            • C# at Google Style Guide

                                                              C# at Google Style Guide This style guide is for C# code developed internally at Google, and is the default style for C# code at Google. It makes stylistic choices that conform to other languages at Google, such as Google C++ style and Google Java style. Formatting guidelines Naming rules Naming rules follow Microsoft’s C# naming guidelines. Where Microsoft’s naming guidelines are unspecified (e.g

                                                              • Secure Randomness in Go 1.22 - The Go Programming Language

                                                                Computers aren’t random. On the contrary, hardware designers work very hard to make sure computers run every program the same way every time. So when a program does need random numbers, that requires extra effort. Traditionally, computer scientists and programming languages have distinguished between two different kinds of random numbers: statistical and cryptographic randomness. In Go, those are

                                                                  Secure Randomness in Go 1.22 - The Go Programming Language
                                                                • 🤓 So you're using a weird language 🧠

                                                                  Tuesday, September 13, 2022 :: Tagged under: engineering. ⏰ 11 minutes. Hey! Thanks for reading! Just a reminder that I wrote this some years ago, and may have much more complicated feelings about this topic than I did when I wrote it. Happy to elaborate, feel free to reach out to me! 😄 🎵 The song for this post is I, Don Quixote from the musical Man of La Mancha, composed by Mitch Leigh and Joe

                                                                    🤓 So you're using a weird language 🧠
                                                                  • Why APL is a language worth knowing

                                                                    “A language that doesn't affect the way you think about programming, is not worth knowing.”, by Alan J. Perlis. Why APL is a language worth knowing Alan Perlis, the computer scientist recipient of the first Turing award, wrote “A language that doesn't affect the way you think about programming, is not worth knowing.” ― Alan J. Perlis, 1982. Special feature: Epigrams on programming. ACM Sigplan Not

                                                                      Why APL is a language worth knowing
                                                                    • Rust needs an official specification - Blog - Tweede golf

                                                                      Can we currently reason about Rust code with absolute certainty? Not really, but we should be able to. In this article, we dive into the reasons why it may be time for a Rust specification. A simple C++ questionIf you know a little bit of C++: can you tell me what the output of the following program is? #include <stdio.h> struct Foo { ~Foo() { puts("Goodbye!"); } // runs when Foo is destructed };

                                                                        Rust needs an official specification - Blog - Tweede golf
                                                                      • Integrating Code Completion in Visual Studio Code - Strumenta

                                                                        Integrating Code Completion in Visual Studio Code – With the Language Server Protocol Introduction Automatic code completion, also known as IntelliSense, is an important part of the modern software development experience. No matter if you’re a programmer writing code in a general-purpose programming language, or a business expert writing rules in some domain-specific language; your editor is incom

                                                                          Integrating Code Completion in Visual Studio Code - Strumenta
                                                                        • ScalaTest

                                                                          Using matchers ScalaTest provides a domain specific language (DSL) for expressing assertions in tests using the word should. Just mix in should.Matchers, like this: import org.scalatest.flatspec._ import org.scalatest.matchers.should._ class ExampleSpec extends AnyFlatSpec with Matchers { ... You can alternatively import the members of the trait, a technique particularly useful when you want to tr

                                                                          • JavaScript Interview Questions

                                                                            Here is a list of common JavaScript interview questions with detailed answers to help you prepare for the interview as a JavaScript developer. JavaScript continues to be a cornerstone of web development, powering dynamic and interactive experiences across the web. As the language evolves, so does the complexity and scope of interview questions for JavaScript developers. Whether you’re a fresher de

                                                                              JavaScript Interview Questions
                                                                            • How to Get or Create in PostgreSQL

                                                                              "Get or create" is a very common operation for syncing data in the database, but implementing it correctly may be trickier than you may expect. If you ever had to implement it in a real system with real-life load, you may have overlooked potential race conditions, concurrency issues and even bloat! In this article I explore ways to "get ot create" in PostgresSQL. Illustration by Abstrakt Design Ta

                                                                                How to Get or Create in PostgreSQL
                                                                              • Renato Athaydes

                                                                                Revisiting Prechelt’s paper and follow-ups comparing Java, Lisp, C/C++ and scripting languages A discussion on programming languages' impact on productivity and program efficiency. In 1999, Lutz Prechelt published a seminal article on the COMMUNICATIONS OF THE ACM (October 1999/Vol. 42, No. 10) called Comparing Java vs. C/C++ Efficiency Differences to Interpersonal Differences, henceforth Java VS

                                                                                • What Makes the Zig Programming Language Unique?

                                                                                  Zig mascot Zero the ZiguanaCompile-time computing was pioneered by the Lisp programming language in the 1960s. Compile-time computing means that the code you later compile isn’t just what you wrote down. What you compile later is also code that is “written” by your code. Code generating code. While a common feature in dynamically typed languages such as Lisp and Julia, it has been rare in statical

                                                                                    What Makes the Zig Programming Language Unique?