iT邦幫忙

python3相關文章
共有 1020 則文章

技術 leetcode with python:70. Climbing Stairs

題目: You are climbing a staircase. It takes n steps to reach the top. Each tim...

技術 leetcode with python:69. Sqrt(x)

題目: Given a non-negative integer x, compute and return the square root of x....

技術 leetcode with python:67. Add Binary

題目: Given two binary strings a and b, return their sum as a binary string. 給定兩...

技術 leetcode with python:66. Plus One

題目: You are given a large integer represented as an integer array digits, where...

技術 leetcode with python:58. Length of Last Word

題目: Given a string s consisting of words and spaces, return the length of the l...

技術 leetcode with python:53. Maximum Subarray

題目: Given an integer array nums, find the contiguous subarray (containing at le...

技術 leetcode with python:3. Longest Substring Without Repeating Characters

題目: Given a string s, find the length of the longest substring without repeatin...

技術 leetcode with python:35. Search Insert Position

題目: Given a sorted array of distinct integers and a target value, return the in...

技術 leetcode with python:28. Implement strStr()

題目: Given two strings needle and haystack, return the index of the first occurr...

技術 leetcode with python:27. Remove Element

題目: Given an integer array nums and an integer val, remove all occurrences of v...

技術 leetcode with python:2. Add Two Numbers

由於前面幾題easy覺得難度還可以負荷,因此開始嘗試medium的題目 題目: You are given two non-empty linked list...

技術 leetcode with python:26. Remove Duplicates from Sorted Array

題目: Given an integer array nums sorted in non-decreasing order, remove the dupl...

技術 leetcode with python:21. Merge Two Sorted Lists

題目: You are given the heads of two sorted linked lists list1 and list2. Merge...

技術 leetcode with python:20. Valid Parentheses

題目: Given a string s containing just the characters '(', ')', '{', '}', '[' and...

技術 leetcode with python:14. Longest Common Prefix

題目: Write a function to find the longest common prefix string amongst an array...

技術 leetcode with python:13. Roman to Integer

題目: Roman numerals are represented by seven different symbols: I, V, X, L, C, D...

技術 leetcode with python:9. Palindrome Number

題目: Given an integer x, return true if x is palindrome integer.An integer is a...

技術 leetcode with python:1. Two Sum

從今天起在此紀錄用python寫leetcode的心路歷程希望能以一天兩三題的速率下去更新讓自己的程式更加精進 題目: Given an array of i...

技術 python入門學習day 4

主題: 變量類型 & 進位制 在Python語言中,我們可以使用變量來保存數據,變量有不同的類型,變量可以做運算,變量還可進行類型轉換 #使用type檢...

技術 小白簽到: 紀錄python學習day 1

#背景: 有理工宅的身形但目前尚無無程式內涵的python初心者,本科系跟理工完全無關的非理工科系畢業半路出家者,期待跟大家一起成長~#學習時間: 2022/0...

技術 終端執行py.ipynb檔

這裡用來紀錄最近的發現 在終端(window+R -> cmd)執行jupyter notebook的ipynb轉py檔時出現了錯誤 "exec...

技術 MacOS讀取藍牙搖桿訊號,利用python修改pynput程式碼實現 - 3.修改pynput

請參考之前的文章:第二篇 5. 修改pynput if event_type == Quartz.NSSystemDefined: sys_event...

技術 MacOS讀取藍牙搖桿訊號,利用python修改pynput程式碼實現 - 2.研究 pynput

請參考之前的文章:第一篇 4. 研究 pynput 首先,在Visual Studio Code界面中,將滑鼠移動到from pynput.keyboard i...

技術 MacOS讀取藍牙搖桿訊號,利用python修改pynput程式碼實現 - 1.起始

1. 前言: 之前想要實現在幾公尺外遙控 mac book,於是就在蝦皮上找到了這個藍牙搖桿,雖然懷疑產品能不能正常使用,不過看在價格99元的份上,還是買來嘗試...

技術 [Python]決策數01─運用CART做決策樹

Hi! 大家好,我是Eric,這次要來用Python做決策樹。 緣起:決策樹因為相對於其他機器學習模型而言,是較易被解釋的,所以是蠻常見的分類方法。...

技術 [Python]回歸模型01─運用OLS做回歸

Hi! 大家好,我是Eric,這次要來用Python做回歸模型。 緣起:回歸模型是常見的分析方法,可用來分析數值變數之間的關係。 方法:運用 [P...

達標好文 技術 【Python OCR 使用手冊】圖片轉文字 超簡單上手

OCR x Pytesseract 前言 在 Python 中, 使用 OCR (Optical Character Recognition , 字元辨識)將...

技術 [Python]使用Pillow,將圖片由RGB轉灰階(Grayscale)

RGB -> Gray scaleGray scale(灰階影像) from PIL import Image img2 = Image.open('GI...

技術 [Django] 解決 django.db.utils.OperationalError: 3780

因為我的 devel env 跟實際 production env 有太多的不同,所以我實際 deploy 的時候經常會出現一堆奇怪的問題。這邊會嘗試不定期記錄...

技術 用 Python 暢玩 Line bot - 30:Line Notify(三)

在上篇中,我們是需要到 Line Notify 登入後的個人介面發行 token,但總不能叫每一個加入 line bot 的好友都自己去註冊 Line Noti...