Computer Science, asked by Hahao2568, 1 year ago

C# how to convert string to datetime format and return string

Answers

Answered by Anonymous
1
That's simple to answer: It's not possible, so stop trying.

Proof: Any format includes M.d.yyyy as well as d.M.yyyy. In that case, 1.2.2016 can represent either

the first of February or

the second of January.

Conclusion: A translation from any format is not possible, since it's not possible to parse ambiguous dates without additional information.

Note: This has nothing to do with C# or your technology of choice. Your requirements are broken. Fix them.

Similar questions