The client sends login credentials, the server checks matches the credentials
This is an incomplete list:
- Make spritesheet of all images.
- Use CDN for static websites
- Use Audit tools (Chrome)
- Google PageSpeed
- Minify the CSS and JavaScript you are using
- Reduce the HTTP request
- Optimize the images as much possible
Note this command.
find . -not -path '*/\.*' -iname '*' -maxdepth 1 -mtime -1
Let's cut it open and see what's happening.
find .
: This says find in the current directory (.
is cwd).-not -path '*/\.*'
: This says not to match dot (hidden) files.-iname '*'
: This says match*
(any name). Thei
ininame
is for case-insensitive.-mtime -1
: This says only match files which are modified less than 1 day(s) ago. If-
is turned to+
, it will say only match files which are not modified after one day which is same as matching every file which are modified after one day.
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
package main | |
import ( | |
"fmt" | |
"os" | |
"github.com/aws/aws-sdk-go/aws" | |
"github.com/aws/aws-sdk-go/aws/session" | |
"github.com/aws/aws-sdk-go/service/s3" | |
) |
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
6.1101,17.592 | |
5.5277,9.1302 | |
8.5186,13.662 | |
7.0032,11.854 | |
5.8598,6.8233 | |
8.3829,11.886 | |
7.4764,4.3483 | |
8.5781,12 | |
6.4862,6.5987 | |
5.0546,3.8166 |
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
package main | |
import ( | |
"encoding/json" | |
"fmt" | |
"net/http" | |
"os" | |
) | |
const clientID = "<your client id here>" |
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
package main | |
import ( | |
"fmt" | |
"math/rand" | |
"sync" | |
"time" | |
) | |
// Worker pool is a collection of threads which are waiting |
- Add concurrency.
- Now deal with it.
- Mutexes, somaphores, context switching
- Check for race condition.
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
package main | |
import "fmt" | |
type SalaryCalculator interface { | |
CalculateSalary() int | |
} | |
type Permanent struct { | |
empId int |