Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
var debug = process.env.NODE_ENV !== "production"; | |
var webpack = require('webpack'); | |
module.exports = { | |
context: __dirname, | |
devtool: debug ? "inline-sourcemap" : null, | |
entry: "./js/scripts.js", | |
output: { | |
path: __dirname + "/js", | |
filename: "scripts.min.js" |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
"""Count words.""" | |
count={} | |
def count_words(s, n): | |
"""Return the n most frequently occuring words in s.""" | |
wordlist = s.split() | |
wordfreq = [wordlist.count(p) for p in wordlist] | |
zip_l=dict(zip(wordlist,wordfreq)) | |
sort=sorted(zip_l.iteritems(),key=lambda(k,v):(-v,k)) |
// @remove-on-eject-begin | |
/** | |
* Copyright (c) 2015-present, Facebook, Inc. | |
* All rights reserved. | |
* | |
* This source code is licensed under the BSD-style license found in the | |
* LICENSE file in the root directory of this source tree. An additional grant | |
* of patent rights can be found in the PATENTS file in the same directory. | |
*/ | |
// @remove-on-eject-end |