2 Jun 2012

Graphics programs

#include <conio.h>
#include <graphics.h>
#include <stdlib.h>
#include <stdio.h>

void main (int)
{
int gdriver=DETECT,gmode,errorcode; //Requesting auto-detection.
int midx,midy,x;
//Initializing graphics and local variables.
initgraph(&gdriver,&gmode,"d:\\bc3\\bgi");
//Reading result of initialization.
errorcode=graphresult();
if(errorcode!=grOk)
//An error occurred.
{
printf("Graphics error occurred : %s \n",grapherrormsg(errorcode));
printf("Press any key to stop : ");
getch();
exit(1); //Terminate the program due to error.
}

setfillstyle(EMPTY_FILL,0);
/*The above statement means that the setfillstyle function is used to
set the fill style of the 3-d bar as a blank.*/
bar3d(200,200,300,450,10,1);
getch();
closegraph();
}
http://www.syvum.com/cgi/online/serve.cgi/squizzes/cpp/cpp_p19a.html

This program shows pre-defined values.

#include <iostream.h>
#include <conio.h>

void main()
{
  clrscr();
  int x = 10;
  float y = 10.1;
  char z = 'a';
  cout << "x = " << x << endl;
  cout << "y = " << y << endl;
  cout << "z = " << z << endl;
  getch();
}
output:
x = 10
y = 10.1
z = a

8 Mar 2012


कविता

कधी कधी मनाला
सहजच काहीतरी सुचतं,
विचार करता करता ते
कविताच करत बसतं.

मनातील भावना जणू
कवितेत माझ्या उतरतात,
इतरांजवळ हळूच त्या
गुपित माझं उलगडतात.

मनावरचं ओझं थोडं
कमी झाल्यासारखं वाटतं,
ऐकणारं जेव्हा कुणीतरी
कवितेरूपी माझ्याजवळ असतं.

3 Mar 2012

काय गरज आहे मला...

काय गरज आहे मला...
शब्दांत तुला गुंफायची..
कदाचीत अजुनही नाही
माझी पात्रता..
तुला व्यक्त करण्याची..
तुझ्या अदा...तुझं लाजणं..
तुझं हसणं...तुझं बोलणं..
सारं कसं...रेखीव.
मुर्तीमंत सौंदर्याचं लेणं..
अन मी...म्हणजे अगदीच..
एखाद्या निश्चल कातळापरी....
कोणाच्यातरी नजरेची वाट
पाहात पहुडलेला...
त्याच ज्ञात अज्ञाताच्या
पाऊलवाटेवर...
म्हणुनच कदाचीत कोणाचीही अनोळखी
पाऊले वाजली की मन आजही