This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT * FROM table_name | |
WHERE 1 = 2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Button(props) { | |
const handleClick = () => props.onClickFunction(props.increment); | |
return ( | |
<button | |
onClick={handleClick} > | |
+{props.increment} | |
</button>); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#The strongly-typed approach(es) | |
The approach that we chose to retrieve the appsettings.json configuration values | |
makes use of the generic IConfiguration object, which can be queried using the | |
preceding string-based syntax. This approach is rather practical; however, if we want | |
to retrieve this data in a more robust way, for example, in a strongly typed fashion, we | |
can—and should—implement something better. Although we won't cover that in | |
more depth in this book, we suggest you read the following great articles, showing | |
three different approaches to achieving this result: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ValidAnagram(first, second) { | |
if(first.length !== second.length){ | |
return false; | |
} | |
const lookup = {}; | |
for(let i = 0; i < first.length; i++){ | |
let letter = first[i]; | |
// if letter exists, increment or set to 1 |