File: example_hashmaps_key_test.f90

package info (click to toggle)
fortran-stdlib 0.8.1-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 34,008 kB
  • sloc: f90: 24,178; ansic: 1,244; cpp: 623; python: 119; makefile: 13
file content (15 lines) | stat: -rw-r--r-- 443 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
program example_key_test
  use stdlib_kinds, only: int8
  use stdlib_hashmaps, only: chaining_hashmap_type
  use stdlib_hashmap_wrappers, only: key_type, set
  implicit none
  type(chaining_hashmap_type) :: map
  type(key_type) :: key
  logical :: present
  
  call map%init()
  call set(key, [0_int8, 1_int8])
  call map%key_test(key, present)
  print *, "Initial key of 10 present for empty map =  ", present
  
end program example_key_test