diff --git a/C#/Datastructures/Nodes/DoublyLinkedListNode.cs b/C#/Datastructures/Nodes/DoublyLinkedListNode.cs index e96befd..9d262ff 100644 --- a/C#/Datastructures/Nodes/DoublyLinkedListNode.cs +++ b/C#/Datastructures/Nodes/DoublyLinkedListNode.cs @@ -10,7 +10,6 @@ namespace C_.Datastructures.Nodes { public T? Value { get; set; } = default; public DoublyLinkedListNode? Next { get; set; } = default; - public DoublyLinkedListNode? Prev { get; set; } = default; public static DoublyLinkedListNode Create(T? value, DoublyLinkedListNode? next, DoublyLinkedListNode? prev) diff --git a/C#/Datastructures/Nodes/StackNode.cs b/C#/Datastructures/Nodes/StackNode.cs new file mode 100644 index 0000000..4735bf9 --- /dev/null +++ b/C#/Datastructures/Nodes/StackNode.cs @@ -0,0 +1,22 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; + +namespace C_.Datastructures.Nodes +{ + internal class StackNode + { + public T? Value { get; set; } = default; + public StackNode? Next { get; set; } = default; + + public static StackNode Create(T? value, StackNode? next) + { + return new StackNode + { + Value = value, + Next = next + }; + } + } +} \ No newline at end of file