---
title: "What does the @ symbol represent in objective-c."  
description: "What does the @ symbol represent in objective-c."  
author: "Tarun Kumar"  
published: 2015-08-02  
updated: 2020-09-18  
canonical: https://www.mindstick.com/interview/12749/what-does-the-symbol-represent-in-objective-c  
category: "iphone"  
tags: ["iphone", "ios", "objective c"]  
reading_time: 2 minutes  

---

# What does the @ symbol represent in objective-c.

**Objective-C** frameworks typically do not use C-style strings. Instead, they pass strings around as NSString objects.

The NSString class provides an object wrapper for strings that has all of the advantages you would expect, including built-in memory management for storing arbitrary-length strings, support for Unicode, printf-style formatting utilities, and more. Because such strings are used commonly though, Objective-C provides a shorthand notation for creating NSString objects from constant values. To use this shorthand, all you have to do is precede a normal, double-quoted string with the @ symbol, as shown in the following examples:

```
NSString *myString = @"My String\n";NSString *anotherString = [NSString stringWithFormat:@"%d %@", 1, @"String"];
```

## Answers

### Answer by Tarun Kumar

**Objective-C** frameworks typically do not use C-style strings. Instead, they pass strings around as NSString objects.

The NSString class provides an object wrapper for strings that has all of the advantages you would expect, including built-in memory management for storing arbitrary-length strings, support for Unicode, printf-style formatting utilities, and more. Because such strings are used commonly though, Objective-C provides a shorthand notation for creating NSString objects from constant values. To use this shorthand, all you have to do is precede a normal, double-quoted string with the @ symbol, as shown in the following examples:

```
NSString *myString = @"My String\n";NSString *anotherString = [NSString stringWithFormat:@"%d %@", 1, @"String"];
```


---

Original Source: https://www.mindstick.com/interview/12749/what-does-the-symbol-represent-in-objective-c

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
