BuziCon - HWzone Forums
adplus-dvertising
Skip to content
  • Create an account

BuziCon

registered user
  • Number of messages

    9
  • Join

  • Recently visited

Recent Visitors

Visitors to your profile are disabled, and you can not see who recently visited your profile.

The ratings of BuziCon

Zone Newbie

Newbie Zone (1/6)

0

Rating

  1. I'm a bit of a truthful woman. I have no idea if there is a solution to this problem
  2. Ok. So I chose this directory, downloaded it, etc. Everything needed, according to this video: https://www.youtube.com/watch?v=D4cKL0HoN1U&ab_channel=TigerPunchSportsClubTigerPunchSportsClub Only problem is, I have an Exception thrown at 0x00007FF8FEDB44C3 (px ) in pybind37Example.pyd: 11xC0: Access violation reading location 0000005x0 Every time I run. And another point is, I'm missing a python0000000000000008_d.dll file. It's not in the Python file of the visual studio.
  3. I built a program in c ++ of an admission system to the institution. (As part of the acton, so do not ask why in c ++, etc.) and I added a script in Python that sends an email for a certain security. The Python sends an email because the program in c ++ runs the file in Python by the cmd. Now I wanted to ask, if there is a more normal way to do this, because I can not actually know what the program in Python sent (say security code) or control where the program in Python will send The email. (Because I run the script via the cmd, which means that there is already a built-in program that c ++ runs it.) I work with VS 2019 Thank you
  4. Is there any website or website that explains the matter in detail?
  5. #include #include using namespace std; struct Node {int data; Node * next; Node * prev; }; struct List {Node * head; Node * tail; }; void Insert (List h, int new_data) {struct Node newNode; newNode.data = new_data; if (h.head == NULL) {newNode.next = NULL; newNode.prev = NULL; h.head = & newNode; // its will be point to the last node in list h.tail = & newNode; } else {// "the first node will point (prev) to new node" h.head-> prev = & newNode; // the new node will point (next) to the first node newNode.next = h.head; newNode.prev = NULL; // the head will point to the new node, and its will be first now h.head = & newNode; }} void displayList (struct List h) {// cout << h.head-> data; } void main () {struct List list; list.head = NULL; list.tail = NULL; Insert (list, 23); Insert (list, 234); displayList (list); } Okay .. so this is the code, and it's folding. The problem is like you said, that every insert makes me a copy.
  6. Without the * list yes, it just remains from one of the experiments I did .. The problem you raised in the Insert function is my real problem, every time it points to null because a new temporary object is created. How can one get the real object, and not a copy of it?
  7. #include #include #include using namespace std; struct Node {int data; Node * next; Node * prev; }; struct List {Node * head; Node * tail; }; void Insert (List * h, int new_data) {struct Node newNode; newNode.data = new_data; if (h.head == NULL) {newNode.next = NULL; newNode.prev = NULL; h.head = & newNode; h.tail = & newNode; } else {h.head-> prev = & newNode; newNode.next = h.head; newNode.prev = NULL; h.head = & newNode; }} void displayList (struct List & h) {} void main () {struct List list; list.head = NULL; list.tail = NULL; Insert (list, 23); Insert (list, 234); displayList (list); } This is the written code
  8. Hello, I build a two-way linked list in c ++, by creating an object called a List that is supposed to point to the beginning and end of the list, and creating a node that is supposed to point to the one before it and the one after it. The problem, in the function of Insert (insert to the beginning of the list), I did (want to do anyway ..) that he get the list, and build a new node, in the first case if the list points to null, then he points to it, and if not points to null, then the new member What the list pointed for, and the list will point to it. Very simple. The problem is that every time he enters a function he supposedly picks up a new list that points to null, and then there is no option to insert new members. I mean, he's making me a copy, not the original list. I tried to send the address but that means I am sending a pointer, and then the voters who have access to the list do not have access to them or anything. #include #include using namespace std; struct Node {int data; Node * next; Node * prev; }; struct List {Node * head; Node * tail; }; void Insert (List h, int new_data) {struct Node newNode; newNode.data = new_data; if (h.head == NULL) {newNode.next = NULL; newNode.prev = NULL; h.head = & newNode; h.tail = & newNode; } else {h.head-> prev = & newNode; newNode.next = h.head; newNode.prev = NULL; h.head = & newNode; }} void displayList (struct List & h) {// cout << h.head-> data; } void main () {struct List list; list.head = NULL; list.tail = NULL; Insert (list, 23); Insert (list, 234); displayList (list); } In this code he creates a new list each time. And if I change the insert function to void Insert (List * h, int new_data) {struct Node newNode; newNode.data = new_data; if (h.head == NULL) {newNode.next = NULL; newNode.prev = NULL; h.head = & newNode; h.tail = & newNode; } else {h.head-> prev = & newNode; newNode.next = h.head; newNode.prev = NULL; h.head = & newNode; }} This creates a problem in all h.head and h.tail. help?
×
  • Create new ...

At the top of the news:

new on the site