並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 19 件 / 19件

新着順 人気順

python list append pop pushの検索結果1 - 19 件 / 19件

  • N番目の素数を求める - すぎゃーんメモ

    SNSなどで話題になっていたので調べてみたら勉強になったのでメモ。 環境 Pythonでの実装例 例1 例2 例3 エラトステネスの篩 Rustでの実装例 試し割り法 エラトステネスの篩 アトキンの篩 おまけ: GMP Benchmark 高速化のテクニック 上限個数を見積もる Wheel factorization オチ Repository References 環境 手元のMacBook Pro 13-inchの開発機で実験した。 2.8 GHz Intel Core i7 16 GB 2133 MHz LPDDR3 Pythonでの実装例 例1 最も単純に「2以上p未満のすべての数で割ってみて余りが0にならなかったら素数」とする、brute force 的なアプローチ。 import cProfile import io import pstats import sys def m

      N番目の素数を求める - すぎゃーんメモ
    • GitHub+CircleCIによる業務要件の記述精度向上の取り組み - ZOZO TECH BLOG

      こんにちは。MSP技術推進部の手塚(@tzone99)です。 この記事では、エンジニア向けのツールを周囲のエンジニア以外のチームにも導入し、チームを跨いだコミュニケーション上の課題を解決した事例をご紹介します。 普段エンジニアとしてプロダクトを開発する中でも、エンジニア同士のやり取りだけで業務が完結しないケースも多いかと思います。周囲のチームとやり取りする中でコミュニケーションのずれが発生した場合の対応として、今回の事例が参考になれば幸いです。 MSP技術推進部の活動について興味のある方はこちらの記事もぜひご覧ください。 techblog.zozo.com techblog.zozo.com techblog.zozo.com techblog.zozo.com 目次 目次 背景 コミュニケーション上の課題 業務要件のMarkdown/PlantUML化 運用の初期対応 自作のLinter

        GitHub+CircleCIによる業務要件の記述精度向上の取り組み - ZOZO TECH BLOG
      • Sublime Text 4

        The first stable release of Sublime Text 4 has finally arrived! We've worked hard on providing improvements without losing focus on what makes Sublime Text great. There are some new major features that we hope will significantly improve your workflow and a countless number of minor improvements across the board. A huge thanks goes out to all the beta testers on discord and all the contributors to

          Sublime Text 4
        • 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
          • Ruby: frozen_string_literalの歴史と現状、未来を考察する(翻訳)|TechRacho by BPS株式会社

            概要 元サイトの許諾を得て翻訳・公開いたします。 英語記事: Frozen String Literals: Past, Present, Future? | byroot’s blog 原文公開日: 2025/10/28 原著者: byroot -- Railsコアコミッター、Rubyコミッターです 日本語タイトルは内容に即したものにしました。 frozenは基本的に英ママとしました。 なお、Ruby 3.4以降ではRUBYOPT環境変数でRUBYOPT="--enable-frozen-string-literal"のように指定すれば、その環境で文字列リテラルをデフォルトでfrozenにできます。 Rubyistの皆さんなら、Rubyソースコードのほどんどのファイル冒頭に# frozen_string_literal: trueというマジックコメントをせっせと書いたり、少なくとも他のプ

              Ruby: frozen_string_literalの歴史と現状、未来を考察する(翻訳)|TechRacho by BPS株式会社
            • Building a Toy Programming Language in Python

              I thought it would be fun to go outside of my comfort zone of web development topics and write about something completely different and new, something I have never written about before. So today, I'm going to show you how to implement a programming language! The project will parse and execute programs written in a simple language I called my (I know it's a lame name, but hey, it is "my" language).

                Building a Toy Programming Language in Python
              • 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

                • 0.8.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

                  • January 2024 (version 1.86)

                    Version 1.106 is now available! Read about the new features and fixes from October. Update 1.86.2: The update addresses these issues. Update 1.86.1: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the January 2024 release of Visual Studio Code. There are many updates in this version that we hope you'll lik

                      January 2024 (version 1.86)
                    • Frozen String Literals: Past, Present, Future?

                      If you are a Rubyist, you’ve likely been writing # frozen_string_literal: true at the top of most of your Ruby source code files, or at the very least, that you’ve seen it in some other projects. Based on informal discussions at conferences and online, it seems that what this magic comment really is about is not always well understood, so I figured it would be worth talking about why it’s there, w

                      • Database Fundamentals

                        About a year ago, I tried thinking which database I should choose for my next project, and came to the realization that I don't really know the differences of databases enough. I went to different database websites and saw mostly marketing and words I don't understand. This is when I decided to read the excellent books Database Internals by Alex Petrov and Designing Data-Intensive Applications by

                          Database Fundamentals
                        • CPythonのソースコードを読んでみた - estie inside blog

                          estieでソフトウェアエンジニアをしている安東です。普段の業務で関わっているのはPython製のシステムが中心ですが、過去データを分析するのにちょっとRustを使ってみたりもしています。 こうやって普段からお世話になっているPythonですが、中身がわからないまま使い続けることに対してやや不安を感じることがあります。たしかに書き方だけ知っていれば大抵の場面でなんとかなってしまうのでしょうが、それだけではカバーしきれないところがどんなプロジェクトでも突然やってきます。カバーできる範囲を増やすためにも、突然の出来事の予兆を事前に嗅ぎつけるためにも、プログラムが動いている感覚が地に足ついた形でほしいのです。 ということで、今回はPythonの処理系でおそらく一番メジャーなCPythonのソースコードを読んでみようと思います。ただ、ソースコード全体を読むには時間も記事のスペースも足りないので、今

                            CPythonのソースコードを読んでみた - estie inside blog
                          • Flipping Pages: An analysis of a new Linux vulnerability in nf_tables and hardened exploitation techniques

                            This blogpost is the next instalment of my series of hands-on no-boilerplate vulnerability research blogposts, intended for time-travellers in the future who want to do Linux kernel vulnerability research. Specifically, I hope beginners will learn from my VR workflow and the seasoned researchers will learn from my techniques. In this blogpost, I'm discussing a bug I found in nf_tables in the Linux

                            • A from-scratch tour of Bitcoin in Python

                              I find blockchain fascinating because it extends open source software development to open source + state. This seems to be a genuine/exciting innovation in computing paradigms; We don’t just get to share code, we get to share a running computer, and anyone anywhere can use it in an open and permissionless manner. The seeds of this revolution arguably began with Bitcoin, so I became curious to dril

                              • 地面を見下ろす少年の足蹴にされる私

                                Contracts提案(P2900R14)がC++26に向けて採択され、C++26では契約プログラミング機能を言語サポートの下で実践できるようになります。この記事は、その契約プログラミング機能の一部として導入されている違反ハンドラというものについてのお話です。 契約プログラミング機能における違反ハンドラの概要 ユーザー定義違反ハンドラ std::contracts::contract_violation より一般的な利用 外部ツールの共通コールバック機構として 実行時エラーハンドリングのコールバック機能として(P3290R2) プロファイル機能の実行時検査におけるコールバックとして(P3081R0) 未定義動作の実行時ハンドリング機能として(P3100R0, P3229R1, P3205R0) 参考文献 契約プログラミング機能における違反ハンドラの概要 C++26の契約プログラミング機能は

                                  地面を見下ろす少年の足蹴にされる私
                                • LambdaLisp - A Lisp Interpreter That Runs on Lambda Calculus

                                  LambdaLisp is a Lisp interpreter written as an untyped lambda calculus term. The input and output text is encoded into closed lambda terms using the Mogensen-Scott encoding, so the entire computation process solely consists of the beta-reduction of lambda calculus terms. When run on a lambda calculus interpreter that runs on the terminal, it presents a REPL where you can interactively define and e

                                    LambdaLisp - A Lisp Interpreter That Runs on Lambda Calculus
                                  • GitHub - ComfyUI-Workflow/awesome-comfyui: A collection of awesome custom nodes for ComfyUI

                                    ComfyUI-Gemini_Flash_2.0_Exp (⭐+172): A ComfyUI custom node that integrates Google's Gemini Flash 2.0 Experimental model, enabling multimodal analysis of text, images, video frames, and audio directly within ComfyUI workflows. ComfyUI-ACE_Plus (⭐+115): Custom nodes for various visual generation and editing tasks using ACE_Plus FFT Model. ComfyUI-Manager (⭐+113): ComfyUI-Manager itself is also a cu

                                      GitHub - ComfyUI-Workflow/awesome-comfyui: A collection of awesome custom nodes for ComfyUI
                                    • 【R&D DevOps通信】AWS Step Functions で失敗したステップから再開する方法 - Sansan Tech Blog

                                      こんにちは、R&D Architectグループの藤岡です。今回は Step Functions(以下SFn) が実行途中で失敗した場合に、失敗した時点から再開できるような仕組みを実現したので、その内容について共有します。 <2024/2/8追記> AWS公式で Step Functions の失敗した時点から再開する機能がサポートされたので、この記事の内容は古くなりました。 https://aws.amazon.com/jp/about-aws/whats-new/2023/11/aws-step-functions-restarting-workflows-failure/ 背景と課題 今回、R&D内で稼働しているバッチの1つに関してシステムのリプレイスを行うことになりました。リプレイスを行う理由は主に以下の2つです。 バッチが途中で失敗した際の復旧作業が複雑になっていた。 バッチで処理

                                        【R&D DevOps通信】AWS Step Functions で失敗したステップから再開する方法 - Sansan Tech Blog
                                      • Philosophy of coroutines

                                        [Simon Tatham, initial version 2023-09-01, last updated 2025-03-25] [Coroutines trilogy: C preprocessor | C++20 native | general philosophy ] Introduction Why I’m so enthusiastic about coroutines The objective view: what makes them useful? Versus explicit state machines Versus conventional threads The subjective view: why do I like them so much? “Teach the student when the student is ready” They s

                                        1