首页    新闻    小组    威客    人才    下载    博客    代码贴    在线编程    论坛
代码贴随便看看全站
#include <stdio.h>
#include <stdlib.h>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */

int gcd(int,int);
int main(void) {
int result;
result=gcd(150,35);
printf("The gcd of 150 and 35 is %i\n",result);
result=gcd(1026,405);
print("The gcd of 1026 and 405 is %i\n",result);
......................
阅读全部 | 瑶湖礼泊 贴于 2014年9月21日 09:28     hide bbsi
package QQ9_20;

import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

......................
阅读全部 | taohappy 贴于 2014年9月20日 23:02     hide bbsi
#include<stdio.h>
#include<string.h>
void fun (char *p,char *q,char*c)
{
int k=0;
while(*p||*q)
{
if(*p<*q)c[k]=*q;
else c[k]=*p;
if(*p)p++;
if(*q)q++;
k++;
......................
阅读全部 | 陆思雨 贴于 2014年9月17日 08:11     hide bbsi
//
public static boolean deleteDirectory(File path) {
if (path.exists()) {
File[] files = path.listFiles();
if (files == null) {
return true;
}
for (File file : files) {
if (file.isDirectory()) {
deleteDirectory(file);
} else {
file.delete();
......................
阅读全部 | 静夜思 贴于 2014年9月16日 17:51     hide bbsi
Toast toast = Toast.makeText(getActivity(), "sldjfasdkjf", Toast.LENGTH_LONG);
toast.setGravity(Gravity.CENTER, 0, 0);
toast.show();
阅读全部 | 静夜思 贴于 2014年9月16日 14:02     hide bbsi
Create Function [dbo].[fn_BitTest32](@num int,@bitpostion int)
Returns bit
As
Begin
--测试某位是否为真
Declare @Rst bit=0
Declare @bit int 
If (@bitpostion>=1 And @bitpostion<=31)
Begin 
Set @bit=Power(2,@bitpostion)
If((@num & @bit)=0)
        Set @Rst=0
......................
阅读全部 | mxbing1984 贴于 2014年8月23日 17:22     hide bbsi
Create Procedure [dbo].[sp_Converter](@TransType tinyint,@sInText nVarchar(4000),@sOutText nVarchar(4000) OUTPUT) 
AS
Begin
Declare @App int
Declare @Doc int
Declare @Err int
Declare @Selection int

Exec @Err = sp_OACreate 'Word.Application', @App OUT
If @err<>0 goto lb_err
Exec @Err = sp_OACreate 'Word.Document', @Doc OUT
If @err<>0 goto lb_err
......................
阅读全部 | mxbing1984 贴于 2014年8月23日 17:21     hide bbsi
DECLARE @hr INT;
DECLARE @objExcel INT;
DECLARE @objWorkBooks INT;
DECLARE @objWorkBook INT;
DECLARE @objSheets INT;
DECLARE @objSheet INT;
DECLARE @objRange INT;
Declare @A INT


EXEC @hr = sp_OACreate 'Excel.Application',@objExcel OUTPUT;
EXEC @hr = sp_OASetProperty @objExcel,'Visible','True';
......................
阅读全部 | mxbing1984 贴于 2014年8月23日 17:20     hide bbsi
Create Procedure sp_MSJZ(@N int)
As
Begin
If @N<3 or @N%2=0
Begin
Print '请输入大于2的奇数'
Return
End

--定义I,J行列和值
Declare @I int=1,@J int,@K int,@X int,@Y int,@T int,@R int

......................
阅读全部 | mxbing1984 贴于 2014年8月23日 17:20     hide bbsi
Create Procedure sp_Upload(@path Varchar(200))
As
Begin
Set NoCount on
/*
Create Table myFile
(
ID int Identity(1,1),
filename Varchar(100),
files Varbinary(max)
)
*/
......................
阅读全部 | mxbing1984 贴于 2014年8月23日 17:19     hide bbsi
上一页 216 217 218 219 220 221 222 223 224 225 下一页