What do you want to save?
Add Code snippet
New code examples
-
Other 2021-10-23 15:56:11
RegExp validation for password explained
r'^ (?=.*[A-Z]) // should contain at least one upper case (?=.*[a-z]) // should contain at least one lower case (?=.*?[0-9]) // should contain at least one digit (?=.*?[!@#\$&*~]) // should contain at least one Special charact... Add solution -
PHP 2021-10-20 09:42:09
php make text id attribute safe
function seoUrl($string) { //Lower case everything $string = strtolower($string); //Make alphanumeric (removes all other characters) $string = preg_replace("/[^a-z0-9_\s-]/", "", $string); //Clean up multiple dashes or white... Add solution -
C 2021-10-19 19:01:06
C string convert All Uppercse To Lowercase
#include <stdio.h> #include <string.h> int main() { char s[100]; int i; printf("\nEnter a string : "); gets(s); for (i = 0; s[i]!='\0'; i++) { i... Add solution -
PHP 2021-10-18 13:49:08
string to lowercase accentuation hyphenated
<?php /** * Converts string to SEO-friendly form (lowercase hyphenated alphanumeric words) * * @param $string * @return string */ function seoUrl($string) { // qv stackoverflow.com/questions/11330480, stackoverflow.com/questions/1017599 ... Add solution -
Other 2021-10-15 08:41:04
word level text generation keras
import string # load doc into memory def load_doc(filename): # open the file as read only file = open(filename, 'r') # read all text text = file.read() # close the file file.close() return text # turn a doc into clean tokens def clean... Add solution -
Shell/Bash 2021-10-12 01:35:05
shell sh if passwords not equal
Codeecho "enter the password" read password len="${#password}" if test $len -ge 8 ; then echo "$password" | grep -q [0-9] if test $? -eq 0 ; then &nb... Add solution -
Java 2021-10-08 16:07:08
string code
// Java code to illustrate different constructors and methods // String class. import java.io.*; import java.util.*; class Test { public static void main (String[] args) { String s= "GeeksforGeeks"; // or String s= new String ("Geeks... Add solution -
TypeScript 2021-09-30 14:08:04
why are lower case alphabets more preffered in html
If you stick with lower case, you'll find it easier to work with the developer tools, because the code you see in the DOM view will be more consistent with the source code you've written. The only relevant parts of specifications say: HTML tag and attribu... Add solution