Codium config

This commit is contained in:
2025-02-23 14:06:33 +01:00
parent 99e98b1766
commit 957e7395ce
4 changed files with 357 additions and 0 deletions

View File

@ -0,0 +1,45 @@
{
"C++ Template": {
"prefix": "C++ template",
"body": [
"$BLOCK_COMMENT_START",
" Descrizione: $1",
" Autore: Tian Cheng Xia",
" Data: $CURRENT_DATE/$CURRENT_MONTH/$CURRENT_YEAR $CURRENT_HOUR:$CURRENT_MINUTE:$CURRENT_SECOND",
"$BLOCK_COMMENT_END",
"#include <iostream>",
"using namespace std;",
"",
"int main() {",
" $0",
" return 0;",
"}"
],
"description": "C++ template"
},
"Execution time": {
"prefix": "exectime",
"body": [
"#include <iostream>",
"#include <ctime>",
"using namespace std;",
"",
"int main() {",
" clock_t t_start, t_end;",
" t_start = clock();",
"",
" // Code --",
" $0",
" // -------",
"",
" t_end = clock();",
" double time = double(t_end - t_start) / double(CLOCKS_PER_SEC);",
" cout.precision(17);",
" cout <<\"Tempo di esecuzione: \" << fixed <<time <<\" s\";",
" return 0;",
"}"
],
"description": "C++ template"
}
}

View File

@ -0,0 +1,15 @@
{
"Centered figure": {
"prefix": [ "\\figure" ],
"body": [
"\\begin{figure}[H]",
"\t\\centering",
"\t\\includegraphics[width=$2\\linewidth]{$1}",
"\t\\caption{",
"\t\t\\parbox[t]{$2\\linewidth}{$3}",
"\t}",
"\\end{figure}",
],
"description": "Centered figure"
}
}