This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<iostream.h> | |
void main() | |
{ | |
int num; | |
num=5; | |
cout.fill('0');//设置填充字符 | |
cout.width(5);//设置域宽 | |
cout<<num<<endl; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
self.view.backgroundColor = [UIColor underPageBackgroundColor]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1.打开Terminal | |
2. svn ls svn://192.168.0.5/client_iphone/ (此处地址可能是http或https类型) | |
3.重启xcode。完毕。 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <string.h> | |
#include <openssl/rsa.h> | |
#include <openssl/applink.c> | |
void print_buf_hex( unsigned char *buf, int len ) | |
{ | |
int i; | |
for( i = 0; i < len; i++ ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static NSString *CellIdentifier = @"MyCell"; | |
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; | |
if (cell == nil) { | |
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleValue2 | |
reuseIdentifier:CellIdentifier] autorelease]; | |
} | |
cell.textLabel.text = @"Label'; | |
cell.detailTextLabel.text = @"Multi-Line\nText"; | |
cell.detailTextLabel.numberOfLines = 2; | |
cell.detailTextLabel.lineBreakMode = UILineBreakModeWordWrap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 6.0以上 | |
- (NSAttributedString *)pickerView:(UIPickerView *)pickerView attributedTitleForRow:(NSInteger)row forComponent:(NSInteger)component { | |
NSString *text = [NSString stringWithFormat:@"R%d C%d", row, component]; | |
NSMutableAttributedString *as = [[NSMutableAttributedString alloc] initWithString:text]; | |
NSMutableParagraphStyle *mutParaStyle=[[NSMutableParagraphStyle alloc] init]; | |
mutParaStyle.alignment = NSTextAlignmentCenter; | |
[as addAttribute:NSParagraphStyleAttributeName value:mutParaStyle range:NSMakeRange(0,[text length])]; | |
return as; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
ftp ftp的地址 | |
login username password | |
ls >c:\a.txt | |
这样就把ftp的文件列到a.txt里面了。 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//先备份该文件 | |
svn remove --force filename //强制删除 | |
//再将无版本信息的备份文件拷贝回来 | |
svn resolve --accept=working filename | |
svn commit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#获取所有信息 | |
ipconfig getpacket en0 | |
#获取路由器ip | |
ipconfig getoption en0 router |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
__block UIBackgroundTaskIdentifier backgroundTaskIdentifier = [[UIApplication sharedApplication] beginBackgroundTaskWithExpirationHandler:^{ | |
NSLog(@"Background Time:%f",[[UIApplication sharedApplication] backgroundTimeRemaining]); | |
[self endBackgroundTask:backgroundTaskIdentifier]; | |
backgroundTaskIdentifier = backgroundTaskIdentifier; | |
}]; |
OlderNewer