⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 substr.c

📁 操作系统SunOS 4.1.3版本的源码
💻 C
字号:
/*	Copyright (c) 1984 AT&T	*//*	  All Rights Reserved  	*//*	THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T	*//*	The copyright notice above does not evidence any   	*//*	actual or intended publication of such source code.	*/#ident	"@(#)substr.c 1.1 92/07/30 SMI" /* from S5R3 acct:lib/substr.c 1.3 *//*	Place the `len' length substring of `as' starting at `as[origin]'	in `aresult'.	Return `aresult'.   Note: The copying of as to aresult stops if either the	specified number (len) characters have been copied,	or if the end of as is found.	A negative len generally guarantees that everything gets copied.*/char *substr(as, aresult, origin, len)char *as, *aresult;int origin;register unsigned len;{	register char *s, *result;	s = as + origin;	result = aresult;	++len;	while (--len && (*result++ = *s++)) ;	if (len == 0)		*result = 0;	return(aresult);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -