Skip to content

Instantly share code, notes, and snippets.

@volkansalma
volkansalma / hill.cpp
Created March 27, 2011 09:00
hill climbing algoritması
//f(bd) = |20 * bir_sayisi(bd) - 100| fonksiyonunu max yapan
// 30 karakterlik binary dizisinin(bd) hill climbing algoritmasi ile
//bulunmasi.
//Volkan SALMA. http://volkansalma.blogspot.com
#include <iostream>
#include <vector>
#include <stdlib.h> //for rand funct.
#include <time.h> //time for rand function seed.
#include <math.h> // for abs function
@volkansalma
volkansalma / gist:627767
Created October 15, 2010 07:20
Naive Bayes Sınıflandırıcı. http://volkansalma.blogspot.com
#include <iostream>
#include <vector>
#include <fstream>
#include <cmath>
using namespace std;
struct FeatureVector
{