We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Print the Elements of a Linked List
Print the Elements of a Linked List
Sort by
recency
|
842 Discussions
|
Please Login in order to post a comment
Javascript
static void printLinkedList(SinglyLinkedListNode head) {
SinglyLinkedListNode current = head; while (current != null) { System.out.println(current.data); current = current.next; } }
import java.io.; import java.math.; import java.security.; import java.text.; import java.util.; import java.util.concurrent.; import java.util.regex.*;
public class Solution {
Python 3 Solution