Closed ashishsme14 closed 3 years ago
While that's an interesting challenge, this seems like a more general Swift question and is not an issue involving the specific elements of Swift for TensorFlow. You might find similar questions on Stack Overflow (this one, for example) or on the Swift forums, and you would probably be better served by searching on those sites first.
We need to write swift code using Link List. Conditions are -
func insert(data:Int) insert data to the list and return nothing. count:Int keep track of the number of the nodes in the link head:Node holds the first element reference. Just implement inset() and count.
Question
We had written as -
We getting output as -
**Input as 5 1 2 3 4 5
Our Output as 5 5 4 3 2 1
Expected Output as 5 1 2 3 4 5**