Under Terminal > Preferences... > (Profile) > Advanced, "Declare terminal as:" should be set to xterm-256color.
This is easy with homebrew:
brew install screen
| #include <iostream> | |
| #include <string> | |
| using namespace std; | |
| class Shape { | |
| protected: | |
| string c; // color | |
| int w; // weight | |
| public: |
| # (1) | |
| def check(x, data: dict, label: dict): | |
| if len(x) == 0: return | |
| for key, value in label.items(): | |
| if x[0] in value and x[0] in label['num']: | |
| data['num'] += int(x[0]) + 1 | |
| elif x[0] in value: data[key] += 2 | |
| return check(x[1:], data, label) | |
| def countSymbol(): |
| #include <stdio.h> | |
| float f1(int a, int b) { | |
| return (float) b/a + b%a; | |
| } | |
| int f2() { | |
| enum MONTH { Jan, Feb = 2, Mar, Apr, May, Jun = 9, Jul }; | |
| return (Jun/Apr + May%3 + Jan*Jul); | |
| } |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| typedef struct Student { | |
| int studentID; | |
| double GPA; | |
| struct Student* next; /* problem 1-1 */ | |
| } Student_t; | |
| void printStudentInfo(Student_t* current) { |
Under Terminal > Preferences... > (Profile) > Advanced, "Declare terminal as:" should be set to xterm-256color.
This is easy with homebrew:
brew install screen
This document is written to help JavaScript developers to understand JavaScript's weird parts deeply and to prepare for interviews, the following resources was really helpful to write this document:
| syn on "语法支持 | |
| set laststatus=2 "始终显示状态栏 | |
| set tabstop=2 "一个制表符的长度 | |
| set softtabstop=2 "一个制表符的长度(可以大于tabstop) | |
| set shiftwidth=2 "一个缩进的长度 | |
| set expandtab "使用空格替代制表符 | |
| set smarttab "智能制表符 | |
| set autoindent "自动缩进 | |
| set smartindent "只能缩进 | |
| set number "显示行号 |
| alias git='LANG=en_GB git' | |
| # Load version control information | |
| autoload -Uz vcs_info | |
| precmd() { vcs_info } | |
| # Format the vcs_info_msg_0_ variable | |
| zstyle ':vcs_info:git:*' formats '(%b)' | |
| # Set up the prompt (with git branch name) |