What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-11-15 20:03:37
capitlize strung js
With performance metrics... // 10,889,187 operations/sec function capitalizeFirstLetter(string) { return string[0].toUpperCase() + string.slice(1); } // 10,875,535 operations/sec function capitalizeFirstLetter(string) { return string.charAt(0).t... Add solution -
Javascript 2021-11-14 17:10:19
how to make a check if letters are capital in discord js
var test = "HELLO"; var upper = test.toUpperCase(); return test === upper; // true // other example var test = "Hello"; var upper = test.toUpperCase(); return test === upper; // false Add solution -
Javascript 2021-11-13 16:31:15
sorting array of objects in javascript by using select option
var items = [ { name: 'Edward', value: 21 }, { name: 'Sharpe', value: 37 }, { name: 'And', value: 45 }, { name: 'The', value: -12 }, { name: 'Magnetic', value: 13 }, { name: 'Zeros', value: 37 } ]; // sort by value items.sort(function (a, b) ... Add solution -
Shell/Bash 2021-11-13 06:23:22
linux grep
# EXAMPLE 1: look for any files (with names ending in ".c++") for the text "::MethodA(" grep "::MethodA(" *.c++ # EXAMPLE 2: display only the matching file names (not the row too) of the matches grep -l "MethodA(" ... Add solution -
Other 2021-11-12 04:02:14
url case sensitive or not
An Internet address is only case sensitive for everything after the domain name. For example, it does not matter if you use uppercase or lowercase with "computerhope.com," it still reaches the same page. However, when typing the name of the pag... Add solution -
Kotlin 2021-11-12 00:34:08
create a map from list kotlin
fun main() { val numbers = listOf("one", "two", "three", "four") println(numbers.associateBy { it.first().toUpperCase() }) println(numbers.associateBy(keySelector = { it.first().toUpperCase() }, valueTr... Add solution