What do you want to save?
Add Code snippet
New code examples
-
PHP 2021-08-31 21:05:02
php multibyte string shuffle
php > $string = "Pretend I'm multibyte!"; php > $len = mb_strlen($string); php > $sploded = array(); php > while($len-- > 0) { $sploded[] = mb_substr($string, $len, 1); } php > shuffle($sploded); php > echo join('', $splode... Add solution -
Python 2021-08-31 09:02:01
merge all mp4 video files into one file python
from moviepy.editor import * import os from natsort import natsorted L =[] for root, dirs, files in os.walk("/path/to/the/files"): #files.sort() files = natsorted(files) for file in files: if os.path.splitext(file)[1] == '... Add solution -
C# 2021-08-31 07:31:01
capitalize c#
string text = "john smith"; // "John smith" string firstLetterOfString = text.Substring(0, 1).ToUpper() + text.Substring(1); // "John Smith" // Requires Linq! using System.Linq; string firstLetterOfEachWord = string.Join(... Add solution -
Python 2021-08-30 19:18:02
word search puzzle python
An improved (shorter, more efficient) version of the above: #!/usr/bin/python # -*- coding: utf-8 -*- puzzle='''F Y Y H N R D R L J C I N U A A W A A H R N T K L P N E C I L F S A P E O G O T P N H P O L A N D ''' clues = ['ITALY', 'HOLLAND'... Add solution -
Python 2021-08-30 14:24:02
how to return paragraph in python
return ' '.join([""" | a | b | c | d | e | f | g | h | i | j | --+---+---+---+---+---+---+---+---+---+---+ 10|"""," | ".join(tableron[9]),"""| --+---+---+---+---+---+---+---+---+---+-... Add solution -
Other 2021-08-30 04:34:02
find duplicates apps script
/** * Removes duplicate rows from the current sheet. */ function removeDuplicates() { var sheet = SpreadsheetApp.getActiveSheet(); var data = sheet.getDataRange().getValues(); var newData = []; for (var i in data) { var row = data[i]; va... Add solution -
Python 2021-08-30 04:23:02
python generate random string with lenght
import random import string def randStr(chars = string.ascii_uppercase + string.digits, N=10): return ''.join(random.choice(chars) for _ in range(N)) # default length(=10) random string print(randStr()) # random string of length 7 print(randStr(N=7)) ... Add solution
Best helpers
Ranking is empty