This file contains 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
<!doctype html> | |
<html> | |
<head> | |
<meta charset="UTF-8" /> | |
<meta name="viewport" content="width=device-width" /> | |
<title>$title</title> | |
$styles | |
</head> | |
<body> | |
<h1>$title</h1> |
This file contains 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 LINE = require('./line.js'); | |
var line = new LINE(); | |
var email = 'your email'; | |
var password = 'your password'; | |
line.login(email, password, function(error, result) { | |
if (error) { | |
return; | |
} |
This file contains 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
# 注意,這種選擇方法得到的結果 | |
# 一個 row 內會同時含有兩筆資料 | |
# 建議先跑一遍試試看結果 | |
SELECT * | |
FROM `twUniversity`, `twHighSchool` | |
WHERE `twUniversity`.`ipv4` LIKE '140%' AND `twHighSchool`.`ipv4` LIKE '203%' | |
ORDER BY `twUniversity`.`uid`, `twHighSchool`.`uid`; |
This file contains 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
<?php | |
/******** 登入畫面 login.php ********/ | |
if(empty($_SESSION['login_success'])) | |
$_SESSION['login_success'] = ""; | |
if( $_SESSION['login_success'] == "true" ) | |
{ | |
header("Location: index.php"); |
This file contains 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
<?php | |
$str = array("a","a","a","b","b","c","d","d","d"); | |
foreach( array_count_values($str) as $item => $count ) { | |
for( $i = 0; $i < $count; $i++ ) { | |
echo $item."<br/>"; | |
} | |
echo "<hr/>"; | |
} |
This file contains 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
/* | |
* Author: Jeremy Yen Date: 2013.10.10 | |
* http://oj.sslab.cs.nthu.edu.tw/problems/11 | |
* | |
*/ | |
#include <iostream> | |
#include <sstream> | |
using namespace std; |
This file contains 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
/* | |
* Author: Jeremy Yen Date: 2013.10.11 | |
* http://oj.sslab.cs.nthu.edu.tw/problems/11 | |
* | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
int main() |
This file contains 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
/* | |
* Fibonacci Sequence Application | |
* http://oj.sslab.cs.nthu.edu.tw/problems/12 | |
* Authored by Jeremy Yen 2013.10.15 | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
int main() |
This file contains 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
/* | |
* Occurrence Count | |
* http://oj.sslab.cs.nthu.edu.tw/problems/21 | |
* Authored by Jeremy Yen 2013.11.11 | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <ctype.h> // 轉大寫 | |
#define N 100 |
This file contains 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
/* | |
* Hexadecimal Converter | |
* http://oj.sslab.cs.nthu.edu.tw/problems/23 | |
* Authored by Jeremy Yen 2013.11.23 | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> // strlen() | |
#define N 10 |
OlderNewer