Skip to content

Instantly share code, notes, and snippets.

View exemuel's full-sized avatar

Samuel Situmeang exemuel

View GitHub Profile
@exemuel
exemuel / histogram_equalization.m
Created April 27, 2016 03:12
Histogram Equalization
function [ output ] = histogram_equalization( input )
%HISTOGRAM_EQUALIZATION A technique for adjusting image intensities to enhance contrast.
% Example
% -------
% Enhance the contrast of an intensity image using histogram
% equalization.
%
% I = imread('Peppers.bmp');
% J = histeq(I);
% figure, imshow(I), figure, imshow(J)
/* Nama file: prima.c
Menentukan bilangan prima */
#include <stdio.h>
int main()
{
int i, habis = 0;
long x;
@exemuel
exemuel / hrfubah.c
Last active October 21, 2015 17:12
Mengubah huruf kecil menjadi huruf besar
/* Nama file: hrfubah.c
Mengubah huruf kecil menjadi huruf besar */
#include <stdio.h>
#define MASKCHAR 32
int main()
{
unsigned char ch;
@exemuel
exemuel / hitungk.c
Created October 20, 2015 05:40
Menghitung Jumlah Karakter
/* Nama file: hitungk.c *
* Menghitung jumlah karakter */
#include <stdio.h>
int main()
{
int k, nspasi, nlain2, ndigit;
nspasi = nlain2 = ndigit = 0;