File: t_sindex.x

package info (click to toggle)
iraf-rvsao 2.8.3-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 16,456 kB
  • sloc: ansic: 963; lisp: 651; fortran: 397; makefile: 27
file content (23 lines) | stat: -rw-r--r-- 466 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File rvsao/Util/t_sindex.x
# February 6, 1995
# By Doug Mink, Harvard-Smithsonian Center for Astrophysics

# SINDEX -- Use Fortran Index call to find one string in another string

procedure t_sindex()

char	istrng1[SZ_LINE]
char	istrng2[SZ_LINE]
char	fstrng1[SZ_LINE]
char	fstrng2[SZ_LINE]
int	loc

int	index

begin
	call clgstr ("string1",istrng1,SZ_LINE)
	call clgstr ("string2",istrng2,SZ_LINE)

	loc = index (fstrng1,fstrng2)
	CALL clputi ("location",loc)
end