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
/* Program ini membandingkan estimasi trapezoidal rule integral dari F(x)= exp (x) | |
Program ini memerlukan panggilan berikut : | |
-MPI_Init | |
-MPI_Comm_rank | |
-MPI_Comm_size | |
-MPI_Finalize | |
Program Membutuhkan Input: |
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 <stdio.h> | |
#include <stdlib.h> | |
#include <math.h> | |
#include <sys/time.h> | |
#include <mpi.h> | |
double f(double a){ | |
return (a*exp(2*a)); | |
//return a; | |
} |
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: Wes Kendall | |
// Copyright 2011 www.mpitutorial.com | |
// This code is provided freely with the tutorials on mpitutorial.com. Feel | |
// free to modify it for your own use. Any distribution of the code must | |
// either provide a link to www.mpitutorial.com or keep this header in tact. | |
// | |
// An intro MPI hello world program that uses MPI_Init, MPI_Comm_size, | |
// MPI_Comm_rank, MPI_Finalize, and MPI_Get_processor_name. | |
// | |
#include <mpi.h> |
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 | |
try { | |
if ($HTTP_RAW_POST_DATA) | |
{ | |
if ($git_hook_data = json_decode($HTTP_RAW_POST_DATA)) | |
{ | |
$fn = fopen('hook.log.txt', 'w') or die('cant open file'); | |
fwrite($fn, "hook data received at: ".date('Y-m-d H:i:s')."\n"); | |
fwrite($fn, print_r($git_hook_data, true)); |
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
#!/usr/bin/env python | |
#usage : python soundclouddl.py <soundcloud url track/list> | |
import soundcloud | |
import urllib | |
import re | |
import time | |
import os | |
import sys |
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
#prevent ascii error | |
#place at the top of the file :D | |
import codecs | |
import sys | |
streamWriter = codecs.lookup('utf-8')[-1] | |
sys.stdout = streamWriter(sys.stdout) |
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 | |
$apiKey = "api_key"; | |
$messageData = array( | |
"code" => 1001, | |
"subject" => "hai kak zam", | |
"messages" => "hai kak zam", | |
); | |
$registrationIdsArray = array("gcm_id"); |
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
#!/usr/bin/env python | |
import requests | |
import json | |
GCM_URL = "https://android.googleapis.com/gcm/send" | |
API_KEY = "your api key" | |
CLIENT_GCM = ["your device gcm_id"] |
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 | |
$url = "https://android.googleapis.com/gcm/send"; | |
$api_key = "<api key>"; | |
$client_id = array("gcm_id"); | |
$headers = array( | |
"Content-type: application/json", | |
"Authorization: key=" . $api_key, |
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
#!/usr/bin/env python | |
# how to use just create instance from this class, you can set client id or client secret from constructor | |
# Methods | |
# 1. get token get_token() //getting token key | |
# 2. check_token(token) // for checking tokon is valid or not | |
# 3. sending_sms(number, message, token, *args, **kwargs) //sending message => return message id | |
# 4. check_status_message(message_id, token, *args, **kwargs) //check status message | |
# |
OlderNewer