This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var a=WScript.arguments; | |
var f=WScript.CreateObject("Scripting.FileSystemObject"); | |
var d=(new Date()).toLocaleString(); | |
var c=(a.length>0)?a(0):""; | |
var n=WScript.ScriptFullName.replace(/\.\w+/,".txt"); | |
var t=f.OpenTextFile(n,8,true); | |
t.WriteLine( d+" "+c ); | |
t.Close(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/local/bin/perl | |
use strict; | |
use warnings; | |
use Image::Magick; | |
print <<USAGE if $#ARGV==-1; | |
Usage: montage.pl file..` | |
USAGE | |
my $img = new Image::Magick; | |
$img->Read(@ARGV); | |
my $mon=$img->Montage(geometry=>'160',tile=>'2x2'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <openssl/md5.h> | |
int main(int argc,char *argv[]){ | |
MD5_CTX c; | |
FILE *f; | |
unsigned char b[1024]; | |
unsigned char md[MD5_LBLOCK]; | |
size_t n; | |
int i; | |
if(argc!=2){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
<title>Japanese Calendar</title> | |
<!-- stylesheet --> | |
<style type="text/css"> | |
<!-- | |
body { font-size:smaller; } | |
em { font-style: normal; font-weight: bold; background-color: yellow; } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/tcc -run -lpcre | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <pcre.h> | |
int main(int argc,char*argv[]){ | |
int ov[9],errofs; | |
char b[1024]; | |
const char* err; | |
pcre *re=pcre_compile("Revision: (\\d+)",0,&err,&errofs,NULL); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <regex.h> | |
int main(int argc,char*argv[]){ | |
char b[1024],i=-1,n=0; | |
regex_t re; | |
regmatch_t m[9]; | |
if(argc==1)return 1; | |
regcomp(&re,argv[1],REG_EXTENDED|REG_NEWLINE); | |
if(argc>2) n=atoi(argv[2]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<body> | |
<input type='text' id='screen_name'/> | |
<input type='submit' onclick='twit_rss_run();' /> | |
<div id='view'></div> | |
<script> | |
function twit_rss_run(){ | |
var name=document.getElementById('screen_name').value; | |
var v=document.getElementById('view'); | |
var s=document.createElement('script'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> /* rand */ | |
#include <assert.h> | |
int swp_calls=0; | |
void swap(int *s,int *d){ | |
int t=*s; | |
*s=*d; | |
*d=t; | |
swp_calls++; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
$ gcc arg.c | |
$ ./a.out -f -s 10 --longflag --longparam=20 aaa | |
option f | |
option s with value 10 | |
option longflag | |
option longparam with value 20 | |
last option aaa | |
*/ | |
#include <stdio.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
void main(){ | |
int i; | |
for(i=1;i<100;i++){ | |
if(printf("%s%s", | |
(i%3==0)?"Fizz":"", | |
(i%5==0)?"Buzz":"")==0){ | |
printf("%d",i); | |
} | |
puts(""); |
NewerOlder