Can I take this sign(一) out of these words 一丝不苟 and "不屑一顾 or no? I'd like to know if that's optional take or not this sign, because i'm known that a few idioms are used to have this sign, thus i want to know why do they use this and how does it affect the sentence ?
These are both idioms (成语) with fixed structures, so deleting the 一 (yī) = "one" would change the meaning, and make it nonsensical.  This also holds for Chinese words such as 一起 and 第一.


一丝不苟 basically means "[even] one thread not careless", referring to meticulousness.
不屑一顾 basically means "disdain [even] one consideration", or "disdain even considering it once".  However, here it's possible to just say 不屑 = "disdain".


So ordinarily dropping the 一 is not reasonable, and certainly so among fixed idioms.

However, in some non-idiom cases we can drop the 一, such as:


每一个人 can be shorted to 每个人, and
她是一个医生 can be shorted to 她是个医生, and even further to 她是医生.


In these cases it's different: we have a measure word (个) and it's possible to sometimes drop the 一.