View gist:9646915
require 'rexml/document' | |
require 'pp' | |
require 'open-uri' | |
require 'date' | |
MARKTAG = "もきゅ"; | |
user = "kimitoboku035" | |
doc = REXML::Document.new(open("http://b.hatena.ne.jp/#{user}/atomfeed?date=#{Time.now.strftime("%Y%m%d")}")); | |
pp "http://b.hatena.ne.jp/#{user}/atomfeed?date=#{Time.now.strftime("%Y%m%d")}" |
View 22-225702.cpp
#include<iostream> | |
using namespace std; | |
int main(void){ | |
int n; | |
cin >> n; | |
cout << n << "yagist.el test" << endl; | |
return 0; |
View 22-223817.c
#include<stdio.h> | |
int main(void){ | |
int array[3][3]; | |
int i,j; | |
for(i=0;i<3;i++){ | |
for(j=0;j<3;j++){ | |
scanf("%d",&array[i][j]); | |
} | |
} |
View lifgame.c
/* | |
学籍番号,氏名:B131820,川上 賢十 | |
*/ | |
#include<stdio.h> | |
#include<time.h> | |
#include<stdlib.h> | |
#define H 10 | |
#define W 10 |
View levenshtein.c
#include<stdio.h> | |
#include<string.h> | |
int min(int a, int b) { | |
return a<b?a:b; | |
} | |
int levenshtein(char *str1,char *str2){ | |
int str1len = strlen(str1); |
View 03-135420.go
package main | |
import ( | |
"math/rand" | |
"fmt" | |
) | |
View 03-161129.go
package main | |
import ( | |
"fmt" | |
) | |
func Sqrt(x float64) float64 { | |
var z float64 = 10 | |
for i := 0; i < 10; i++ { | |
z = z - (z*z-x)/(2*z) |
View 03-135753.go
package main | |
import ( | |
"fmt" | |
"math" | |
) | |
func main(){ | |
fmt.Printf("Now you have %g problems.",math.Nextafter(2, 3)) | |
} |
View 03-143637.go
package main | |
import ( | |
"fmt" | |
) | |
func add(x int,y int) int { | |
return x+y | |
} |
View 03-155859.go
package main | |
import ( | |
"fmt" | |
) | |
func main() { | |
sum := 0 | |
for i := 0; i < 10; i++ { | |
sum += i |
OlderNewer