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 lang="ID"> | |
<head> | |
<title>OnChange Function JavaScript</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" /> | |
<script type="text/javascript" src="jquery-1.9.1.min.js"></script> | |
</head> | |
<body> | |
<input type="text" name="text1" value="0"/> <br/> |
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: Agung Andika | |
*/ | |
import java.util.ArrayList; | |
import java.util.Scanner; | |
public class Searching { | |
public static void main(String[] args) { | |
// dataList = ArrayList data type | |
// askData = how much array / data will be stored |
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
// filename: Binarysearch.java | |
package Binarysearch; | |
import java.util.Scanner; | |
public class Binarysearch { | |
public static void main(String[] args) { | |
int[] A={1,3,4,7,8,11,13,15,17,19}; | |
int cari, temu=0; | |
int lo = 0, lh = A.length - 1, mid = 0; | |
Scanner scan=new Scanner(System.in); |
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
<!-- BEGIN OF index.php file --> | |
<?php | |
$con=mysqli_connect("localhost","root","","test"); | |
// Check connection | |
if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } | |
$result = mysqli_query($con,"SELECT * FROM `imam`"); | |
while($row = mysqli_fetch_array($result)) { | |
$checkData = $row['headerCheck']; |
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
#include <iostream> | |
using namespace std; | |
void quickSort (int arr[], int kiri, int kanan) ; | |
int main() { | |
int isi = 0, loop = 0, arrSize = 0; | |
cout << "Program QuickSort sederhana\n"; | |
cout << "Berapa besar array? "; cin >> arrSize; | |
int larik[arrSize]; |
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
<script language="JavaScript"> | |
var larik = [4,3,2,9,44,13,77,84,22,19]; | |
var max = larik[0]; var min = larik[0]; | |
var ukuran = larik.length; | |
for (var i = 0; i < ukuran; i++) { | |
if (larik[i] > max) max = larik[i]; | |
else if (larik[i] < min) min = larik[i]; | |
} | |
/** you can use: alert('Max: ' + max + '\nMin: ' + min); **/ |
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 | |
/** | |
* @version 1.0 | |
* @author Rasmus Schultz <http://blog.mindplay.dk/> | |
* @license LGPL3 <http://www.gnu.org/licenses/lgpl-3.0.txt> | |
*/ | |
/** | |
* Helper-class to build SQL queries that calculate the geographical distance |
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 | |
$c = new CDbCriteria(); | |
Hoge::model()->findAll($c); | |
// SELECT * FROM `hoge` `t` | |
$c = new CDbCriteria(); | |
$c->addSearchCondition('t.fuga', null); // null, false, ''などは無視されるようです | |
Hoge::model()->findAll($c); |
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: [email protected] | |
* | |
*/ | |
public class SequenceCase02 { | |
public static void main(String[] args) { | |
int lariknya[] = new int[]{11, 12, 10, 15, 6, 10, 13, 7, 14, 6, 15}; | |
int a = 0; | |
int a_size = lariknya.length; | |
int cari; |
OlderNewer