# 7.1 Character Basic

## 7.1 Character Basic

1. \[0.1] **Declare** a Character Data Type Variable. _(Repeated)_
2. \[0.2] **Assign** a Character Constant in a Character Variable. _(Repeated)_
3. \[0.3] **Initialize** a Character Variable using a Character Constant. _(Repeated)_
4. \[0.4] **Print** the Character Variable. _(Repeated)_

## সমাধান

### \[0.1] Declare a Character Data Type Variable. _(Repeated)_

{% code lineNumbers="true" %}
```c
#include<stdio.h>
int main(){
    char ch;
    
    return 0;
}
```
{% endcode %}

### \[0.2] Assign a Character Constant in a Character Variable. _(Repeated)_

{% code lineNumbers="true" %}
```c
#include<stdio.h>
int main(){
    char ch;
    
    ch = 'A';
    
    return 0;
}
```
{% endcode %}

### \[0.3] Initialize a Character Variable using a Character Constant. _(Repeated)_

{% code lineNumbers="true" %}
```c
#include<stdio.h>
int main(){
    char ch = 'A';
    
    return 0;
}
```
{% endcode %}

### \[0.4] Print the Character Variable. _(Repeated)_

{% tabs %}
{% tab title="Garbage Value" %}
{% code lineNumbers="true" %}
```c
#include<stdio.h>
int main(){
    char ch;
    
    printf("%c\n", ch);
    
    return 0;
}
```
{% endcode %}
{% endtab %}

{% tab title="After Assignment" %}
{% code lineNumbers="true" %}
```c
#include<stdio.h>
int main(){
    char ch;
    ch = 'A';
    
    printf("%c\n", ch);
    
    return 0;
}
```
{% endcode %}
{% endtab %}

{% tab title="After Initialization" %}
{% code lineNumbers="true" %}
```c
#include<stdio.h>
int main(){
    char ch = 'A';
    
    printf("%c\n", ch);
    
    return 0;
}
```
{% endcode %}


{% endtab %}
{% endtabs %}
