2023-01-20 21:48:46 +01:00
|
|
|
package ds
|
|
|
|
|
2023-01-20 22:05:08 +01:00
|
|
|
type LinkedListQueue[T any] struct {
|
|
|
|
*ListQueue[T]
|
|
|
|
}
|
|
|
|
|
|
|
|
var _ Queue[int] = &LinkedListQueue[int]{}
|
2023-01-20 21:48:46 +01:00
|
|
|
|
|
|
|
func NewLinkedListQueue[T any]() *LinkedListQueue[T] {
|
2023-01-20 22:05:08 +01:00
|
|
|
return &LinkedListQueue[T]{
|
|
|
|
ListQueue: NewListQueue[T](NewLinkedList[T]()),
|
|
|
|
}
|
2023-01-20 21:48:46 +01:00
|
|
|
}
|