Skip to content

Instantly share code, notes, and snippets.

View frr149's full-sized avatar

Fernando Rodriguez Romero frr149

View GitHub Profile
// NSSet
NSMutableSet *fraseChorras = [NSMutableSet set];
[fraseChorras addObject:@"Tengo un cimbel matutino"];
[fraseChorras addObject:@"Con la forma de un pepino"];
[fraseChorras addObject:@"Tengo un cimbel matutino"]; // no se añade
NSLog(@"El conjunto: %@", fraseChorras);
// NSCountSet
- (NSInteger)tableView:(UITableView *)tableView
sectionForSectionIndexTitle:(NSString *)title
atIndex:(NSInteger)index{
NSLog(@"Touched on section %@", title);
NSInteger firstStartingWithLetter = 0;
// búsqueda de la primera familia cuyo nombre empieza
// por la letra tocada
for (NSString *familyName in self.familyNames) {
​- (NSInteger)tableView:(UITableView *)tableView
sectionForSectionIndexTitle:(NSString *)title
atIndex:(NSInteger)index{
NSLog(@"Touched on section %@", title);
NSInteger firstStartingWithLetter = 0;
@frr149
frr149 / frr.xcolortheme
Created July 4, 2013 12:07
Tema de Xcode usado en el Curso Online de Desarrollo iOS de Agbo
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Colors</key>
<dict>
<key>Background</key>
<string>0.168627 0.168627 0.207843</string>
<key>InsertionPoint</key>
<string>0.994444 0.988889 1</string>
#import "AGTStarWarsCharacter.h"
@interface AGTWookie : AGTStarWarsCharacter
+(instancetype) wookie;
-(void)fullBodyWax;
@end
#import <Foundation/Foundation.h>
@interface AGTStarWarsCharacter : NSObject
+(instancetype) starWarsCharacter;
@end
@implementation AGTStarWarsCharacter
#import "AGTStarWarsCharacter.h"
@interface AGTWookie : AGTStarWarsCharacter
+(id) wookie;
-(void)fullBodyWax;
@end
#import <Foundation/Foundation.h>
@interface AGTStarWarsCharacter : NSObject
+(id) starWarsCharacter;
@end
@implementation AGTStarWarsCharacter
// Created by Fernando Rodríguez Romero on 24/10/12.
// Copyright (c) 2012 Agbo. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <AudioToolbox/AudioToolbox.h>
int main(int argc, const char * argv[])
{
int main(int argc, const char * argv[], const char *envp[], const char *apple[])
{
// insert code here...
NSLog(@"Printing argv:");
for (int i = 0; i < argc; i++) {
NSLog(@"%s\n", argv[i]);
}
NSLog(@"Printing envp");