What do you want to save?
Add Code snippet
New code examples
-
Python 2021-11-16 13:47:29
python running multiple threads at the same time
import multiprocessing def worker(num): """ Worker procedure """ print('Worker:', str(num)) # Mind the "if" instruction! if __name__ == '__main__': jobs = [] # list of jobs jobs_num = 5 # numbe... Add solution -
SQL 2021-11-16 07:01:28
flask mysql
from flask import Flask, render_template, request from flask_mysqldb import MySQL app = Flask(__name__) app.config['MYSQL_HOST'] = 'localhost' app.config['MYSQL_USER'] = 'root' app.config['MYSQL_PASSWORD'] = 'root' app.config['MYSQL_DB'] = 'MyDB' mysql... Add solution -
Python 2021-11-15 06:40:11
flask cors policy no 'access-control-allow-origin'
# initialization app = Flask(__name__) app.config['SECRET_KEY'] = 'the quick brown fox jumps over the lazy dog' app.config['CORS_HEADERS'] = 'Content-Type' cors = CORS(app, resources={r"/foo": {"origins": "http://localhost:port... Add solution -
Other 2021-11-15 01:37:13
how to make a game with kivy
from kivy.app import App from kivy.uix.widget import Widget from kivy.properties import ( NumericProperty, ReferenceListProperty, ObjectProperty ) from kivy.vector import Vector from kivy.clock import Clock class PongPaddle(Widget): score = Nume... Add solution -
Python 2021-11-14 13:53:15
KivyMD video recording
from kivy.app import App from kivy.uix.widget import Widget from kivy.uix.boxlayout import BoxLayout from kivy.uix.image import Image from kivy.clock import Clock from kivy.graphics.texture import Texture from kivy.properties import StringProperty, Numeri... Add solution -
Other 2021-11-13 17:21:07
dash s;lider
import dash_core_components as dcc import dash_html_components as html from dash.dependencies import Input, Output import dash external_stylesheets = ['https://codepen.io/chriddyp/pen/bWLwgP.css'] app = dash.Dash(__name__, external_stylesheets=external_... Add solution -
Python 2021-11-10 00:27:14
extract audio from .mp4 python .mp3
#!/usr/bin/env python3 """ video_to_mp3.py Description: Simple script to extract MP3 audio from videos using Python. Requirements: - "lame" - "ffmpeg" If the libraries are not installed j... Add solution -
Python 2021-11-09 21:13:22
jwt authentication python flask
from flask import Flask from flask_jwt import JWT, jwt_required, current_identity from werkzeug.security import safe_str_cmp class User(object): def __init__(self, id, username, password): self.id = id self.username = username ... Add solution
Best helpers
Ranking is empty