Skip to content

Instantly share code, notes, and snippets.

View eccstartup's full-sized avatar
🈲
I may be slow to respond.

Yi Lu eccstartup

🈲
I may be slow to respond.
View GitHub Profile

新闻w

RHEL 7 发布应该算是比较大的新闻了吧~

人民群众纷纷表示红帽步子太大不要扯着蛋了比较好...

F_XZ: 完全没关心...

猫注意的新功能有 virtio 等 KVM 优化, docker 支持, 以及 ruby 2.0, python 2.7, java 7 之类的吧

Configuring HCodecs-0.3...
Building HCodecs-0.3...
Preprocessing library HCodecs-0.3...
[1 of 7] Compiling Data.Arbitrary ( src/Data/Arbitrary.hs, dist/dist-sandbox-36d9b399/build/Data/Arbitrary.o )
[2 of 7] Compiling Data.ByteString.Builder ( src/Data/ByteString/Builder.hs, dist/dist-sandbox-36d9b399/build/Data/ByteString/Builder.o )
src/Data/ByteString/Builder.hs:65:1: Warning:
Module ‘Foreign’ does not export ‘unsafePerformIO’
[3 of 7] Compiling Data.ByteString.Parser ( src/Data/ByteString/Parser.hs, dist/dist-sandbox-36d9b399/build/Data/ByteString/Parser.o )

基于 Node.js 和 Express.js 的 RESTful API 服务端开发

开发环境

  • Node.js
    • Arch Linux: 直接使用包管理器安装
    • Ubuntu / Debian / etc: 使用 visionmedia/n
    • OS X / Windows: 使用官方提供的安装包
  • 编辑器
  • WebStorm

##Javascript

###记录

首先,之前有人提到JS语言适合不适合入门?

其实……这个问题并不是太关键,毕竟这里已经接触过编程的人还是很多的

那么,大家的意见如何呢?

##Javascript

###1 嗯,关于执行 JS 的问题预习已经提到过了,确实是要打开 debug 窗口吧

这里 console.log(...) 可以理解成在打印 ... 的内容

其中 ... 可以是文字 "Hello" 也可以是整数 9

###2

function spdiagm{T<:Integer}(B, d::Array{T, 1}, m::Integer, n::Integer)
ndiags = length(d)
ncoeffs = 0
for vec in B
ncoeffs += length(vec)
end
I = Array(T, ncoeffs)
J = Array(T, ncoeffs)
V = Array(Float64, ncoeffs)
id = 0
-- http://www.4clojure.com/problem/148
sumone n a = div (a * (1 + c) * c) 2
where c = div (n - 1) a
sumtwo n a b = sumone n a + sumone n b - sumone n (a * b)
/*****************
* bossFight.js *
*****************
*
* NO FARTHER, DR. EVAL!!!!
* YOU WILL NOT GET OUT OF HERE ALIVE!!!!
* IT'S TIME YOU SEE MY TRUE FORM!!!!
* FACE MY ROBOT WRATH!!!!!
*/
/**********************
* superDrEvalBros.js *
**********************
*
* You're still here?! Well, Dr. Eval, let's see
* how well you can operate with one less dimension.
*
* Give up now. Unless you have a magic mushroom
* up your sleeve, it's all over.
*/