من اجل بداية التعلم يمكنك تلعم c++ او Java
اغلب الدراسات الجامعية تبدأ تدريس طلابها بإحدى هذه الللغتين.
ثم تختار المجال الذي تريده: ويب و اندرويدو ...
على اساسها تحدد اللغات الاحترافية التي تريد تعلمها لتتقدم في المجال
لنفترض تريد بنائها على لغة c++
البناء يتطب عمل struct او class:
#include<iostream>
using namespace std;
class double_linkedlist
{
public:
//structure of the node
struct node
{
string data;
node* next;
node* prev;
node(string x)
{
data = x;
next = NULL;
prev = NULL;
}
};
//the head and tail nodes
node* head;
node* tail;
//The functions
double_linkedlist(); //constructor
~double_linkedlist(); //destructor
void addFront(string); //add in the front
void addBack(string); //add in the back
}
//constructor
doubleLinkedList::doubleLinkedList(){
head = tail = NULL;
}
//destructor
doubleLinkedList::~doubleLinkedList(){
node* current = head;
while(current != NULL)
{
node* previous = current;
current = current->next;
delete previous;
}
head = tail = NULL;
}
//Your functions is in below
void doubleLinkedList::addFront(int x){
node* n = new node(x);
n->next = head;
n->prev = NULL;
if (head != NULL)
head->prev = n;
head = n;
if (tail == NULL)
tail = n;
}
void doubleLinkedList::addBack(int x){
node* n = new node(x);
n->next = NULL;
n->prev = tail;
tail = n;
}
//The main fucntion
int main()
{
doubleLinkedList list1;
return 0;
}
يمكنك استدعاء الدالة في main بالشكل التالي:
list1->addFront("ypur name");
list1->addBack("Example"):
ليس من الضروري
هناك العديد من المواقع العربية , مثل هرمش تقدم محتوى جيد في البرمجة باختلاف مجالاتها.
لكن يبقى المحتى الانكليزي في الصدارة من ناحية الجودة الاكاديمية , والسرعة في التعلم.