i want to creat program by far pointers, when i oprate it in text mode screen it will show characters in the another direction.
ex: if the screen is " remove the disk " after operating program it'll be " ksid eht evomer
thanks & waiting ur help
i want to creat program by far pointers, when i oprate it in text mode screen it will show characters in the another direction.
ex: if the screen is " remove the disk " after operating program it'll be " ksid eht evomer
thanks & waiting ur help
خذي الكود :
مع أننا لانحل أكواد جاهزة مباشرة ,, لكن بما أنها المرة الأولى فلا بأس ,, وحلها سهل ,, حيث أننا سنضع البيانات في مصفوفة عادية ونقوم بطباعة عناصر المصفوفة بالعكس فقط ,,
#include <iostream.h>
void main()
{
char x[20];
char y[20];
cin>>x;
for(int q=0;q<20;q++)
y[q]=x[19-q];
cout<<y;
cin.get();
{وهذا كود ثاني بس ب pointer نفس حل الاخ هيثم
#include <iostream.h>
#include <conio.h>
#include <stdio.h>
void main()
{
int l;
char x[20];
char* xptr;
gets(x);
l=strlen(x);
xptr=&x[l];
for(int q=0;q<l+1;q++)
cout<<*xptr--;;
getch();
}هذا الموضوع مغلق.