你好,Hugo

这是使用Hugo创建的站点中的第一篇文章。

package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
)

func main() {
	fmt.Printf("%b", 5)
	r := bufio.NewReader(os.Stdin)
	f, _ := strconv.ParseFloat(readline(r), 64)
	p1, _ := strconv.Atoi(readline(r))
	p2, _ := strconv.Atoi(readline(r))
	total := int(f * (1 + float64(p1+p2)/100))
	fmt.Printf("The total meal cost is %d dollars.\n", total)
}

func readline(r *bufio.Reader) (s string) {
	for {
		line, prefix, _ := r.ReadLine()
		s = s + string(line)
		if !prefix {
			break
		}
	}
	return
}
#!/bin/bash

###### CONFIG
ACCEPTED_HOSTS="/root/.hag_accepted.conf"
BE_VERBOSE=false

if [ "$UID" -ne 0 ]
then
 echo "Superuser rights required"
 exit 2
fi

genApacheConf(){
 echo -e "# Host ${HOME_DIR}$1/$2 :"
}
下一页
comments powered by Disqus