Notes
![]() ![]() Notes - notes.io |
Solution 1:
using System;
class Class9
{
static void Main0(string[] args)
{
String[] arr = new string[] { "1", "2", "false", "", "3", "null", "4" };
String[] arr2 = new string[] { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
String[] res = new string[10];
foreach(string i in arr)
{
foreach(string j in arr2)
{
if(i.Equals(j))
{
Console.WriteLine(j);
}
}
}
}
}
Solution 2:
class Class10
{
static void Main22(string[] args)
{
int[] arr = new int[] { 83, 5, 6, 3, 2, 67, 83, 5, 7 };
Console.WriteLine("Before removing duplicates:");
foreach(int i in arr) Console.WriteLine(i);
int[] res = arr.Distinct().ToArray();
Console.WriteLine("After removing duplicates:");
foreach(int k in res) Console.WriteLine(k);
}
}
Solution 3:
class Class11
{
Boolean compare(int[] a, int[] b)
{
if (a.SequenceEqual(b)) return true;
else return false;
}
static void Main23(string[] args)
{
int[] arr1 = { 1, 2, 3 };
int[] arr2 = { 1, 2, 3 };
Class11 obj = new Class11();
if (obj.compare( arr1, arr2)==true)
{
Console.WriteLine("Equal");
}
else
{
Console.WriteLine("Not Equal");
}
}
}
Solution 4:
class Class12
{
static void Main(string[] args)
{
string str = "She sells sea shells on the sea shore ";
int l = 0, ctr =0, chctr=0;
while (l <= str.Length-1)
{
if (str[l]==' ' || str[l]=='n' || str[l] == 't')
{
ctr++;
}
l++;
}
Console.WriteLine("Number of words: " + ctr);
int i = 0;
while(i < str.Length)
{
if ((str[i]>='a' && str[i] <= 'z') || (str[i] >= 'A' && str[i] <= 'Z'))
{
chctr++;
}
i++;
}
Console.WriteLine("Number of characters: " + chctr);
}
}
![]() |
Notes is a web-based application for online taking notes. You can take your notes and share with others people. If you like taking long notes, notes.io is designed for you. To date, over 8,000,000,000+ notes created and continuing...
With notes.io;
- * You can take a note from anywhere and any device with internet connection.
- * You can share the notes in social platforms (YouTube, Facebook, Twitter, instagram etc.).
- * You can quickly share your contents without website, blog and e-mail.
- * You don't need to create any Account to share a note. As you wish you can use quick, easy and best shortened notes with sms, websites, e-mail, or messaging services (WhatsApp, iMessage, Telegram, Signal).
- * Notes.io has fabulous infrastructure design for a short link and allows you to share the note as an easy and understandable link.
Fast: Notes.io is built for speed and performance. You can take a notes quickly and browse your archive.
Easy: Notes.io doesn’t require installation. Just write and share note!
Short: Notes.io’s url just 8 character. You’ll get shorten link of your note when you want to share. (Ex: notes.io/q )
Free: Notes.io works for 14 years and has been free since the day it was started.
You immediately create your first note and start sharing with the ones you wish. If you want to contact us, you can use the following communication channels;
Email: [email protected]
Twitter: http://twitter.com/notesio
Instagram: http://instagram.com/notes.io
Facebook: http://facebook.com/notesio
Regards;
Notes.io Team