Category: Algorithm

16
Feb
2017

URI Online Judge | 1030 Flavious Josephus Legend

This is level 3 problem so will do it later. But this video will help for  sure….

23
Jul
2016

Draw Midpoint Circle Algorithm with Keyboard Function

Midpoint algo reference: http://www.eazynotes.com/notes/computer-graphics/algorithms/mid-point-circle-algorithm.pdf http://suraj1693.blogspot.com/2013/11/c-program-for-drawing-circle-using.html https://birunthag.blogspot.com/2014/05/openglc-draw-circle-with-midpoint.html https://www.opengl.org/discussion_boards/showthread.php/169955-using-glutKeyboardFunc Code: #include <windows.h> #include <GL\glut.h> #include <stdlib.h> #include<iostream> #include<stdio.h> using namespace…

17
Jul
2016

Draw Brasenham Line Drawing Algorithms with Random Lines and Colors

Code: #include <windows.h> #include <GL\glut.h> #include <stdlib.h> #include<iostream> using namespace std; int x, y, a, b, nol,…

30
Jun
2016

How to count numbers from string ?

code: #include<stdio.h> #include<stdlib.h> int main(){ char line[]=”1 -2 10000 -50 20 7 445 -4″; char *p,*e; long…

31
Dec
2015

Depth Firtst Search(DFS) Algorithm Explanation and Implementation in C++

Discovery Time and Finishing Time Code: //dfs using adjacency list in directed graph #include<iostream> using namespace std;…

02
Dec
2015

What does it actually mean in an array limit 0≤A[i]≤10^10 ?

Its means that the value of A[i] must be remained between 0 to 10000000000