我正在使用AutoIt Recorder记录我的所有点击次数,但它重播的速度太快了。我怎么能慢下来呢?
我可以使用$ path -l g++ gcc
lrwxr-xr-x 1 root admin 23 Dec 6 2014 /opt/local/bin/g++ -> /opt/local/bin/g++-mp-5
-rwxr-xr-x 1 root wheel 18176 Jul 8 22:52 /usr/bin/g++
lrwxr-xr-x 1 root admin 23 Dec 6 2014 /opt/local/bin/gcc -> /opt/local/bin/gcc-mp-5
-rwxr-xr-x 1 root wheel 18176 Jul 8 22:52 /usr/bin/gcc
$ /usr/bin/g++ --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 8.0.0 (clang-800.0.42.1)
Target: x86_64-apple-darwin15.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
$ /usr/bin/gcc --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 8.0.0 (clang-800.0.42.1)
Target: x86_64-apple-darwin15.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
,但我不想把它放在每一行之后。
答案 0 :(得分:1)
您可以使用:
#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <iostream>
int main(void)
{
//setting names of ints and chars.
FILE *file_in, *file_in2, *file_out;
int wordcount, linecount, charcount, i = 100;
char letter, letter2;
char filename1[50];
char filename2[50];
char output [50];
//setting all counts to 0.
wordcount = 0;
linecount = 0;
charcount = 0;
//Gets the user to enter name of file, then puts it in string.
printf("\n Enter first text document\n");
scanf("%s", filename1);
printf("\n Enter Second text document\n");
scanf("%s", filename2);
//opens then reads the first file and checks if the document has opened correctly.
file_in = fopen(filename1, "r");
if (file_in == NULL)
{
fprintf(stderr, "The %s file failed to open!", filename1);
return 1;
}
// counts the number of words, then lines, then letters in doc 1.
while ((letter = getc(file_in)) != EOF)
{
if (letter == ' ')
{
wordcount++;
}
else if (letter == '\n')
{
linecount++;
}
else
{
charcount++;
}
}
//opens then reads the second file and checks if the document has opened correctly.
file_in2 = fopen(filename2, "r");
if (file_in2 == NULL)
{
fprintf(stderr, "The %s file failed to open!", filename2);
return 1;
}
// counts the number of words, then lines, then letters in doc 2.
while ((letter2 = getc(file_in2)) != EOF)
{
if (letter2 == ' ')
{
wordcount++;
}
else if (letter2 == '\n')
{
linecount++;
}
else
{
charcount++;
}
}
//displays the total on screen.
printf("words: %d\n", wordcount);
printf("Lines: %d\n", linecount);
printf("Characters: %d\n", charcount);
//asks for output file name
printf("Enter output file: ");
scanf("%s", output);
//opens the output file to write
file_out = fopen (output, "w");
fseek(file_in, 0, SEEK_SET);
fseek(file_in2, 0, SEEK_SET);
while (((letter = getc(file_in)) != EOF) || ((letter2 = getc(file_in2)) != EOF))
{
fputc(letter, file_out);
if (letter == '\n')
{
}
fputc(letter2, file_out);
if (letter2 == '\n')
{
}
}
fclose(file_in);
fclose(file_out);
}
默认为10毫秒。所以慢慢增加它。有关更多信息,请查看: https://www.autoitscript.com/autoit3/docs/functions/AutoItSetOption.htm