| | |
switch case problem with characters
Please support our C advertiser: Programming Forums - DaniWeb Sister Site
Thread Solved |
•
•
Join Date: Feb 2008
Posts: 38
Reputation:
Solved Threads: 0
Hello guys,
How can I make a switch case using an array of chars.
Ex:
Is that possible in C?
Thank you!
How can I make a switch case using an array of chars.
Ex:
C Syntax (Toggle Plain Text)
char input[50]; // my code here switch ( input ) { case "abc": // do something break; case "xyz": // do otherthings break; }
Is that possible in C?
Thank you!
![]() |
Similar Threads
- scientific calculator using switch case statement (C++)
- Reputed number problem switch case statement (VB.NET)
- Switch Case Problem (C++)
- switch case (C)
- Switch Case Options (C#)
- Help with switch/case statement navigation (PHP)
- Switch Case Statement (Java)
- switch/case statement (C++)
Other Threads in the C Forum
- Previous Thread: read e-mail attachment with POP3
- Next Thread: passing structuce to function as an argument
| Thread Tools | Search this Thread |
Tag cloud for C
adobe ansi api array arrays bash binarysearch centimeter char convert copyanyfile copypdffile cprogramme createcopyoffile createprocess() csyntax directory drawing dynamic executable fflush file floatingpointvalidation fork frequency getlasterror getlogicaldrivestrin givemetehcodez global graphics gtkgcurlcompiling hardware highest homework i/o ide inches infiniteloop initialization interest kilometer lazy linked linkedlist linux linuxsegmentationfault list logical_drives match matrix meter microsoft motherboard multi mysql odf open opendocumentformat openwebfoundation pattern pause pdf pointer pointers posix power problem program programming pyramidusingturboccodes read recursion recv repetition scanf scheduling segmentationfault send shape single socketprograming socketprogramming spoonfeeding stack standard strchr string strings structures student suggestions system test testautomation unix urboc user voidmain() win32api windows.h






