- (void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event{
UIView * view = [[UIView alloc]initWithFrame:CGRectMake(, , , )];
view.backgroundColor = [UIColor orangeColor];
view.alpha = ;
[self.view addSubview:view];
//动画持续时间为五秒
[UIView animateWithDuration: animations:^{
view.alpha = ;
}completion:^(BOOL finished) {//当动画结束后进行的操作
//动画时间为一秒
[UIView animateWithDuration: animations:^{
view.alpha = ;
} completion:^(BOOL finished) {
view.backgroundColor = [UIColor blueColor];
}];
}];
}