sudo yum install java-1.8.0-openjdk.x86_64
rpm --import https://artifacts.elastic.co/GPG-KEY-elasticsearch
| const infinityGauntlet = { | |
| powerStone: { | |
| equipped: true, | |
| info: 'Controls all of the power in the universe. It can be used to augment or inhibit any force.', | |
| use() { | |
| if(this.equipped) { | |
| return 'Using super strength to crash the moon and throw it over to the Avengers!!'; | |
| } else { | |
| return 'No power stone!' | |
| } |
Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.
| atom-text-editor { | |
| font-family: 'Fira Code'; | |
| font-style: normal; | |
| text-rendering: optimizeLegibility; | |
| } | |
| atom-text-editor::shadow { | |
| .string.quoted, | |
| .string.regexp { | |
| -webkit-font-feature-settings: "liga" off, "calt" off; | |
| } |
| <?php | |
| // Does string contain letters? | |
| function _s_has_letters( $string ) { | |
| return preg_match( '/[a-zA-Z]/', $string ); | |
| } | |
| // Does string contain numbers? | |
| function _s_has_numbers( $string ) { | |
| return preg_match( '/\d/', $string ); |
| // String utils | |
| // | |
| // resources: | |
| // -- mout, https://github.com/mout/mout/tree/master/src/string | |
| /** | |
| * "Safer" String.toLowerCase() | |
| */ | |
| function lowerCase(str) { | |
| return str.toLowerCase(); |
| /** | |
| * Splits a Pascal-Case word into individual words separated by spaces. | |
| * @param {Object} word | |
| * @returns {String} | |
| */ | |
| function splitPascalCase(word) { | |
| var wordRe = /($[a-z])|[A-Z][^A-Z]+/g; | |
| return word.match(wordRe).join(" "); | |
| } |