NCEPLIBS-w3emc  2.11.0
w3ai24.f
Go to the documentation of this file.
1 C> @file
2 C> @brief Test for match of two strings.
3 C> @author Luke Lin @date 1994-08-31
4 
5 C> Test two strings. If all equal; Otherwise .false.
6 C>
7 C> Program history log:
8 C> - Luke Lin 1994-08-31
9 C>
10 C> @param[in] STRING1 Character array to match with string2
11 C> @param[in] STRING2 Character array to match with string1
12 C> @param[in] LENGTH Integer length of string1 and string2
13 C> @return W3AI24 Logical .true. if s1 and s2 match on all char.,
14 C> logical .false. if not match on any char.
15 C>
16 C> @author Luke Lin @date 1994-08-31
17  LOGICAL FUNCTION w3ai24(STRING1, STRING2,LENGTH)
18 C
19  CHARACTER*1 string1(*)
20  CHARACTER*1 string2(*)
21  INTEGER*4 length
22 C
23  w3ai24 = .true.
24 C
25  DO 10 i = 1,length
26  IF (string1(i).NE.string2(i)) GO TO 40
27  10 CONTINUE
28 C
29  RETURN
30 C
31  40 CONTINUE
32  w3ai24 = .false.
33  RETURN
34 C
35  END
logical function w3ai24(STRING1, STRING2, LENGTH)
Test two strings.
Definition: w3ai24.f:18