Set up project:
mkdir project
cd project
npm init -y
#!/bin/python3 | |
import sys | |
if __name__ == '__main__': | |
n = int(input()) | |
m = 1 | |
i=0 | |
dic = {} | |
for i in range (n): |
#!/usr/bin/python -tt | |
# Copyright 2010 Google Inc. | |
# Licensed under the Apache License, Version 2.0 | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# Google's Python Class | |
# http://code.google.com/edu/languages/google-python-class/ | |
# Basic string exercises | |
# Fill in the code for the functions below. main() is already set up |
# F. front_back | |
# Consider dividing a string into two halves. | |
# If the length is even, the front and back halves are the same length. | |
# If the length is odd, we'll say that the extra char goes in the front half. | |
# e.g. 'abcde', the front half is 'abc', the back half 'de'. | |
# Given 2 strings, a and b, return a string of the form | |
# a-front + b-front + a-back + b-back | |
def front_back(a, b): | |
af = len(a)//2 |
#!/usr/bin/python -tt | |
# Copyright 2010 Google Inc. | |
# Licensed under the Apache License, Version 2.0 | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# Google's Python Class | |
# http://code.google.com/edu/languages/google-python-class/ | |
# Basic list exercises | |
# Fill in the code for the functions below. main() is already set up |
#!/usr/bin/env sh | |
# checks to see if running | |
launchctl list | grep elasticsearch | |
launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.elasticsearch.plist | |
launchctl remove homebrew.mxcl.elasticsearch | |
pkill -f elasticsearch |
#add 'node_modules' to .gitignore file | |
git rm -r --cached node_modules | |
git commit -m 'Remove the now ignored directory node_modules' | |
git push origin master |
When hosting our web applications, we often have one public IP
address (i.e., an IP address visible to the outside world)
using which we want to host multiple web apps. For example, one
may wants to host three different web apps respectively for
example1.com
, example2.com
, and example1.com/images
on
the same machine using a single IP address.
How can we do that? Well, the good news is Internet browsers