This file contains hidden or 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
| #include <stdio.h> | |
| #include <dirent.h> | |
| #include <sys/types.h> | |
| int main() | |
| { | |
| struct dirent *entry; | |
| DIR *dir; | |
| dir = opendir("/home/user1/"); |
This file contains hidden or 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
| //compile: gcc a.c -lmemcached | |
| #include <libmemcached/memcached.h> | |
| #include <stdio.h> | |
| #include <string.h> | |
| int main() | |
| { | |
| memcached_server_st *servers = NULL; | |
| memcached_st *memc; | |
| memcached_return rc; |
This file contains hidden or 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
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| void action(char *a, char *b) __attribute__((nonnull(2))); | |
| void action(char *a, char *b) { | |
| if (a != NULL) { | |
| printf("%s\n", a); | |
| } |
This file contains hidden or 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
| // You can edit this code! | |
| // Click here and start typing. | |
| package main | |
| import "fmt" | |
| type IFeature interface { | |
| GetPrice() int | |
| } |
This file contains hidden or 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" | |
| "log" | |
| "go.etcd.io/bbolt" | |
| ) | |
| func main() { |
This file contains hidden or 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
| add_newline = false | |
| format = "$sudo$username[](bg:#D81E5B fg:#82264f)$directory[](bg:#E23E58 fg:#D81E5B)$git_branch$git_commit$git_state$git_metrics[](fg:#E23E58 bg:#0E131F)$fill[](bg:#0E131F fg:#18212b)$nix_shell[](bg:#18212b fg:#2e294e)$status[](bg:#2e294e fg:#633359)$cmd_duration[](bg:#633359 fg:#973c64)$jobs[](bg:#973c64 fg:#E23E58)$git_status$line_break$character" | |
| [character] | |
| error_symbol = "[ ](red)" | |
| format = "$symbol" | |
| success_symbol = "[ ](purple)" | |
| vimcmd_symbol = "[ ](green)" | |
| [cmd_duration] |
This file contains hidden or 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
| // gcc a.c | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| void clean_name(char **name) { | |
| printf("clean clean!"); | |
| free(*name); | |
| } |
This file contains hidden or 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
| #!/bin/sh | |
| # Iterate over a csv file and aggregate items. | |
| # in BEGIN we define global variables. | |
| # in the middle block we define the logic. | |
| # in the END we define the conclusion logic like prints etc. | |
| # NR>1 means ignore the first line. | |
| awk -F "," 'BEGIN { | |
| delete visited_items; | |
| } | |
| NR>1 { |
This file contains hidden or 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
| { pkgs ? import <nixpkgs> {} }: | |
| # { pkgs ? import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/nixos-23.11.tar.gz") {} }: | |
| with pkgs; | |
| mkShell { | |
| nativeBuildInputs = [ | |
| ]; |
This file contains hidden or 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
| { | |
| "TableName": "Users", | |
| "KeySchema": [{ | |
| "AttributeName": "ID", | |
| "KeyType": "HASH" | |
| }], | |
| "AttributeDefinitions": [{ | |
| "AttributeName": "ID", | |
| "AttributeType": "S" | |
| }], |